Skip to content
This repository has been archived by the owner on Sep 26, 2024. It is now read-only.

Commit

Permalink
Agrim/Pr 3926 remove additional tnc (#7866)
Browse files Browse the repository at this point in the history
* chore: remove additional terms section

* fix: empty commit
  • Loading branch information
agrim-deriv authored Aug 13, 2024
1 parent 3898ced commit 1c3baeb
Show file tree
Hide file tree
Showing 2 changed files with 39 additions and 36 deletions.
1 change: 0 additions & 1 deletion crowdin/messages.json
Original file line number Diff line number Diff line change
Expand Up @@ -4341,7 +4341,6 @@
"-188305238": "Funds & transfers",
"-2100890115": "Security & privacy",
"-732092769": "Risk disclosure",
"-1131400885": "Deriv Investments (Europe) Limited",
"-112814932": "Deriv (FX) Ltd",
"-2019617323": "Deriv (BVI) Ltd",
"-924881302": "This is where you’ll find information about our legal policies and how they apply to you. The documents linked below collectively form our standard terms of use (the “Terms”). It’s important that you make yourself aware of these Terms and agree to them before using any of our websites, products, or services.",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -17,18 +17,25 @@ type ColProps = {
Icon: string
content: TString
title: TString
non_eu_links: Link[]
non_eu_links?: Link[]
eu_links?: Link[]
row_links?: Link[]
}

type Link = {
url: string
title: TString
}

const Col = ({ Icon, content, title, eu_links, non_eu_links }: ColProps) => {
const Col = ({ Icon, content, title, eu_links, non_eu_links, row_links }: ColProps) => {
const { region } = useBuildVariant()
const links = region === "eu" ? eu_links : non_eu_links
let links = non_eu_links

if (region === 'eu') {
links = eu_links
} else if (region === 'row') {
links = row_links
}

return (
<GridCol>
Expand Down Expand Up @@ -91,8 +98,7 @@ const columns: ColProps[] = [
{
Icon: Funds,
title: '_t_Funds & transfers_t_',
content:
'_t_Terms that govern keeping and transferring funds in Deriv and the bonuses you might get_t_',
content: '_t_Terms that govern keeping and transferring funds in Deriv and the bonuses you might get_t_',
eu_links: [
{
url: '/tnc/eu/funds-and-transfers.pdf',
Expand Down Expand Up @@ -126,8 +132,7 @@ const columns: ColProps[] = [
{
Icon: Risk,
title: '_t_Risk disclosure_t_',
content:
'_t_A notice to help you understand the risks that might arise when you trade on Deriv_t_',
content: '_t_A notice to help you understand the risks that might arise when you trade on Deriv_t_',
eu_links: [
{
url: '/tnc/eu/risk-disclosure.pdf',
Expand All @@ -141,34 +146,33 @@ const columns: ColProps[] = [
},
],
},
{
Icon: BFX,
title: '_t_Additional terms_t_',
content: '_t_Additional terms and restrictions for Deriv clients in certain countries_t_',
eu_links: [
{
url: '/tnc/deriv-investments-(europe)-limited-eu.pdf',
title: '_t_Deriv Investments (Europe) Limited_t_',
},
],
non_eu_links: [
{
url: '/tnc/deriv-(fx)-ltd.pdf',
title: '_t_Deriv (FX) Ltd_t_',
},
{
url: '/tnc/deriv-(bvi)-ltd.pdf',
title: '_t_Deriv (BVI) Ltd_t_',
},
{
url: '/tnc/deriv-(v)-ltd.pdf',
title: '_t_Deriv (V) Ltd_t_',
},
],
},
]

const additionalTermsColumn: ColProps = {
Icon: BFX,
title: '_t_Additional terms_t_',
content: '_t_Additional terms and restrictions for Deriv clients in certain countries_t_',
row_links: [
{
url: '/tnc/deriv-(fx)-ltd.pdf',
title: '_t_Deriv (FX) Ltd_t_',
},
{
url: '/tnc/deriv-(bvi)-ltd.pdf',
title: '_t_Deriv (BVI) Ltd_t_',
},
{
url: '/tnc/deriv-(v)-ltd.pdf',
title: '_t_Deriv (V) Ltd_t_',
},
],
}

const IconGrid = () => {
const { region } = useBuildVariant()

const displayedColumns = region === 'row' ? [...columns, additionalTermsColumn] : columns

return (
<StyledContainer>
<StyledGrid
Expand All @@ -179,9 +183,9 @@ const IconGrid = () => {
mobile_columns="1fr"
mobile_row_gap="10rem"
>
{columns.map((col, index) => {
return <Col {...col} key={index} />
})}
{displayedColumns.map((col, index) => (
<Col {...col} key={index} />
))}
</StyledGrid>
</StyledContainer>
)
Expand Down

0 comments on commit 1c3baeb

Please sign in to comment.