Skip to content

Commit 43a365f

Browse files
committed
setup AdoptionChart for translation
1 parent 2442441 commit 43a365f

File tree

2 files changed

+58
-16
lines changed

2 files changed

+58
-16
lines changed

src/components/AdoptionChart.tsx

Lines changed: 46 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,7 @@
11
import React from "react"
22
import { useTheme } from "@emotion/react"
33
import styled from "@emotion/styled"
4+
import Translation from "./Translation"
45

56
const Container = styled.div`
67
display: flex;
@@ -58,27 +59,57 @@ const AdoptionChart: React.FC<IProps> = () => {
5859
return (
5960
<Container>
6061
<Column>
61-
<ColumnName>2010</ColumnName>
62-
<Cell color={isDark ? "#FBF9A5" : "#95935B"}>Investors</Cell>
62+
<ColumnName>
63+
<Translation id="adoption-chart-column-2010-label" />
64+
</ColumnName>
65+
<Cell color={isDark ? "#FBF9A5" : "#95935B"}>
66+
<Translation id="adoption-chart-investors-label" />
67+
</Cell>
6368
</Column>
6469

6570
<Column>
66-
<ColumnName>2014</ColumnName>
67-
<Cell color={isDark ? "#FBF9A5" : "#95935B"}>Investors</Cell>
68-
<Cell color={isDark ? "#9EC885" : "#67954C"}>Developers</Cell>
69-
<Cell color={isDark ? "#E78F6E" : "#CB7C5E"}>Companies</Cell>
71+
<ColumnName>
72+
<Translation id="adoption-chart-column-2014-label" />
73+
</ColumnName>
74+
<Cell color={isDark ? "#FBF9A5" : "#95935B"}>
75+
<Translation id="adoption-chart-investors-label" />
76+
</Cell>
77+
<Cell color={isDark ? "#9EC885" : "#67954C"}>
78+
<Translation id="adoption-chart-developers-label" />
79+
</Cell>
80+
<Cell color={isDark ? "#E78F6E" : "#CB7C5E"}>
81+
<Translation id="adoption-chart-companies-label" />
82+
</Cell>
7083
</Column>
7184

7285
<Column>
73-
<ColumnName>Now</ColumnName>
74-
<Cell color={isDark ? "#FBF9A5" : "#95935B"}>Investors</Cell>
75-
<Cell color={isDark ? "#9EC885" : "#67954C"}>Developers</Cell>
76-
<Cell color={isDark ? "#E78F6E" : "#CB7C5E"}>Companies</Cell>
77-
<Cell color={isDark ? "#8EA8CA" : "#5E7492"}>Artists</Cell>
78-
<Cell color={isDark ? "#AC85C2" : "#88669B"}>Musicians</Cell>
79-
<Cell color={isDark ? "#CA928E" : "#985955"}>Writers</Cell>
80-
<Cell color={isDark ? "#B9B9B9" : "#9E9E9E"}>Gamers</Cell>
81-
<Cell color={isDark ? "#E2B79E" : "#E78A54"}>Refugees</Cell>
86+
<ColumnName>
87+
<Translation id="adoption-chart-column-now-label" />
88+
</ColumnName>
89+
<Cell color={isDark ? "#FBF9A5" : "#95935B"}>
90+
<Translation id="adoption-chart-investors-label" />
91+
</Cell>
92+
<Cell color={isDark ? "#9EC885" : "#67954C"}>
93+
<Translation id="adoption-chart-developers-label" />
94+
</Cell>
95+
<Cell color={isDark ? "#E78F6E" : "#CB7C5E"}>
96+
<Translation id="adoption-chart-companies-label" />
97+
</Cell>
98+
<Cell color={isDark ? "#8EA8CA" : "#5E7492"}>
99+
<Translation id="adoption-chart-artists-label" />
100+
</Cell>
101+
<Cell color={isDark ? "#AC85C2" : "#88669B"}>
102+
<Translation id="adoption-chart-musicians-label" />
103+
</Cell>
104+
<Cell color={isDark ? "#CA928E" : "#985955"}>
105+
<Translation id="adoption-chart-writers-label" />
106+
</Cell>
107+
<Cell color={isDark ? "#B9B9B9" : "#9E9E9E"}>
108+
<Translation id="adoption-chart-gamers-label" />
109+
</Cell>
110+
<Cell color={isDark ? "#E2B79E" : "#E78A54"}>
111+
<Translation id="adoption-chart-refugees-label" />
112+
</Cell>
82113
</Column>
83114
</Container>
84115
)

src/intl/en/page-what-is-ethereum.json

Lines changed: 12 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -96,5 +96,16 @@
9696
"page-what-is-ethereum-the-year-in-ethereum-2021-desc": "Jan 17, 2022 - Josh Stark and Evan Van Ness",
9797
"page-what-is-ethereum-atoms-institutions-blockchains": "Atoms, Institutions, Blockchains",
9898
"page-what-is-ethereum-atoms-institutions-blockchains-desc": "- Why blockchains matter?",
99-
"page-what-is-ethereum-ethereum-in-numbers-title": "Ethereum in numbers"
99+
"page-what-is-ethereum-ethereum-in-numbers-title": "Ethereum in numbers",
100+
"adoption-chart-column-2010-label": "2010",
101+
"adoption-chart-column-2014-label": "2014",
102+
"adoption-chart-column-now-label": "Now",
103+
"adoption-chart-investors-label": "Investors",
104+
"adoption-chart-developers-label": "Developers",
105+
"adoption-chart-companies-label": "Companies",
106+
"adoption-chart-artists-label": "Artists",
107+
"adoption-chart-musicians-label": "Musicians",
108+
"adoption-chart-writers-label": "Writers",
109+
"adoption-chart-gamers-label": "Gamers",
110+
"adoption-chart-refugees-label": "Refugees"
100111
}

0 commit comments

Comments
 (0)