Skip to content

Commit 357d8ad

Browse files
authored
Merge pull request #9964 from ethereum/dev
Deploy v7.10.0
2 parents 2125478 + 023fa6a commit 357d8ad

File tree

378 files changed

+1341
-1436
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

378 files changed

+1341
-1436
lines changed

.storybook/main.js

Lines changed: 1 addition & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -3,13 +3,7 @@ const { propNames } = require("@chakra-ui/react")
33
const { babelConfig } = require("./babel-storybook-config")
44

55
module.exports = {
6-
stories: [
7-
{
8-
directory: "../src/components",
9-
titlePrefix: "Components",
10-
files: "**/*.stories.tsx",
11-
},
12-
],
6+
stories: ["../src/components/**/*.stories.tsx"],
137
addons: [
148
"@storybook/addon-links",
159
"@storybook/addon-essentials",
@@ -87,7 +81,4 @@ module.exports = {
8781
},
8882
},
8983
},
90-
docs: {
91-
autodocs: true,
92-
},
9384
}

.storybook/preview.js

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -31,9 +31,13 @@ export const parameters = {
3131
date: /Date$/,
3232
},
3333
},
34+
backgrounds: {
35+
disable: true,
36+
},
3437
chakra: {
3538
theme,
3639
},
40+
layout: "centered",
3741
// Modify viewport selection to match Chakra breakpoints (or custom breakpoints)
3842
viewport: {
3943
viewports: chakraBreakpointArray.reduce((prevVal, currVal) => {

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "ethereum-org-website",
3-
"version": "7.9.2",
3+
"version": "7.10.0",
44
"description": "Website of ethereum.org",
55
"main": "index.js",
66
"repository": "git@github.com:ethereum/ethereum-org-website.git",

src/@chakra-ui/gatsby-plugin/components/components.utils.ts

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -65,8 +65,8 @@ export {
6565
* @param styleObjs - The following style objects to be merged
6666
*/
6767
export function defineMergeStyles(
68-
defaultTheming?: SystemStyleObject,
69-
...styleObjs: SystemStyleObject[] | undefined[]
70-
) {
68+
defaultTheming?: SystemStyleObject | unknown,
69+
...styleObjs: SystemStyleObject[] | unknown[]
70+
): Record<string, SystemStyleObject> {
7171
return merge(defaultTheming, ...styleObjs)
7272
}

src/components/Banners/BugBountyBanner.tsx

Lines changed: 0 additions & 19 deletions
This file was deleted.

src/components/BeaconChainActions.tsx

Lines changed: 0 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -112,18 +112,6 @@ const BeaconChainActions: React.FC = () => {
112112
<Translation id="page-upgrades-index-staking-learn" />
113113
</ButtonLink>
114114
</Card>
115-
<Card
116-
w="full"
117-
mr={0}
118-
ml={{ base: 0, md: 4 }}
119-
emoji=":computer:"
120-
title={t("consensus-run-beacon-chain")}
121-
description={t("consensus-run-beacon-chain-desc")}
122-
>
123-
<ButtonLink variant="outline" to="/upgrades/get-involved/">
124-
<Translation id="consensus-run-beacon-chain" />
125-
</ButtonLink>
126-
</Card>
127115
</Flex>
128116
<H3>
129117
<Translation id="consensus-explore" />

src/components/CalloutBanner.tsx

Lines changed: 36 additions & 76 deletions
Original file line numberDiff line numberDiff line change
@@ -1,80 +1,17 @@
11
import React from "react"
2-
import styled from "@emotion/styled"
32
import { GatsbyImage, IGatsbyImageData } from "gatsby-plugin-image"
3+
import { Flex, FlexProps, Heading, Image, Text } from "@chakra-ui/react"
44

55
import Translation from "./Translation"
66
import { TranslationKey } from "../utils/translations"
77

8-
const StyledCard = styled.div`
9-
display: flex;
10-
flex-direction: row-reverse;
11-
background: ${({ theme }) => theme.colors.layer2Gradient};
12-
padding: 3rem;
13-
margin: 1rem;
14-
margin-top: 6rem;
15-
margin-bottom: 10rem;
16-
border-radius: 4px;
17-
18-
@media (max-width: ${(props) => props.theme.breakpoints.l}) {
19-
flex-direction: column;
20-
margin-bottom: 1rem;
21-
margin: 4rem 2rem;
22-
}
23-
@media (max-width: ${(props) => props.theme.breakpoints.s}) {
24-
padding: 2rem;
25-
}
26-
`
27-
28-
const Content = styled.div`
29-
padding-left: 2rem;
30-
flex: 1 0 50%;
31-
display: flex;
32-
flex-direction: column;
33-
justify-content: center;
34-
@media (max-width: ${(props) => props.theme.breakpoints.l}) {
35-
margin-top: 2rem;
36-
padding-left: 1rem;
37-
flex-direction: column;
38-
width: 100%;
39-
}
40-
@media (max-width: ${(props) => props.theme.breakpoints.s}) {
41-
padding-left: 0;
42-
}
43-
`
44-
45-
const Description = styled.p`
46-
font-size: 1.25rem;
47-
width: 90%;
48-
line-height: 140%;
49-
margin-bottom: 2rem;
50-
color: ${(props) => props.theme.colors.text200};
51-
`
52-
53-
const Image = styled(GatsbyImage)<{ maximagewidth?: number }>`
54-
align-self: center; /* prevents crop */
55-
width: 100%;
56-
max-width: ${(props) => `${props.maximagewidth}px`};
57-
margin-top: -6rem;
58-
margin-bottom: -6rem;
59-
@media (max-width: ${(props) => props.theme.breakpoints.l}) {
60-
margin-bottom: 0rem;
61-
margin-top: -6rem;
62-
}
63-
`
64-
65-
const H2 = styled.h2`
66-
margin-top: 0rem;
67-
`
68-
69-
export interface IProps {
8+
export interface IProps extends FlexProps {
709
children?: React.ReactNode
7110
image: IGatsbyImageData
7211
maxImageWidth?: number
7312
titleKey: TranslationKey
7413
descriptionKey: TranslationKey
7514
alt: string
76-
className?: string
77-
id?: string
7815
}
7916

8017
const CalloutBanner: React.FC<IProps> = ({
@@ -84,26 +21,49 @@ const CalloutBanner: React.FC<IProps> = ({
8421
descriptionKey,
8522
alt,
8623
children,
87-
className,
88-
id,
24+
...restProps
8925
}) => (
90-
<StyledCard className={className} id={id}>
26+
<Flex
27+
direction={{ base: "column", lg: "row-reverse" }}
28+
bg="layer2Gradient"
29+
p={{ base: 8, sm: 12 }}
30+
borderRadius="base"
31+
{...restProps}
32+
>
9133
<Image
34+
as={GatsbyImage}
9235
image={image}
9336
alt={alt}
94-
maximagewidth={maxImageWidth}
9537
objectFit="contain"
38+
alignSelf="center"
39+
w="full"
40+
maxW={`${maxImageWidth}px`}
41+
mt={-24}
42+
mb={{ base: 0, lg: -24 }}
9643
/>
97-
<Content>
98-
<H2>
44+
<Flex
45+
flexGrow={1}
46+
flexShrink={0}
47+
flexBasis="50%"
48+
direction="column"
49+
justifyContent="center"
50+
pl={{ base: 0, sm: 4, lg: 8 }}
51+
w={{ base: "full", lg: "inherit" }}
52+
>
53+
<Heading
54+
as="h2"
55+
mt={0}
56+
fontSize={{ base: "2xl", sm: "2rem" }}
57+
lineHeight="1.4"
58+
>
9959
<Translation id={titleKey} />
100-
</H2>
101-
<Description>
60+
</Heading>
61+
<Text fontSize="xl" w="90%" lineHeight="140%" mb={8} color="text200">
10262
<Translation id={descriptionKey} />
103-
</Description>
63+
</Text>
10464
{children}
105-
</Content>
106-
</StyledCard>
65+
</Flex>
66+
</Flex>
10767
)
10868

10969
export default CalloutBanner

src/components/PageMetadata.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -125,7 +125,7 @@ const PageMetadata: React.FC<IProps> = ({
125125
if (pathname.includes("/dapps/")) {
126126
ogImage = getSrc(ogImageDapps)
127127
}
128-
if (pathname.includes("/upgrades/")) {
128+
if (pathname.includes("/roadmap/")) {
129129
ogImage = getSrc(ogImageUpgrades)
130130
}
131131
if (image) {

src/components/Staking/ShanghaiCapella.tsx

Lines changed: 0 additions & 98 deletions
This file was deleted.

src/components/Staking/StakingCommunityCallout.tsx

Lines changed: 4 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -10,10 +10,6 @@ import Translation from "../Translation"
1010
import { trackCustomEvent } from "../../utils/matomo"
1111
import { getImage } from "../../utils/image"
1212

13-
const StyledCallout = styled(CalloutBanner)`
14-
margin: 4rem 0;
15-
`
16-
1713
const ButtonContainer = styled.div`
1814
display: flex;
1915
gap: 1rem;
@@ -50,8 +46,10 @@ const StakingCommunityCallout: React.FC<IProps> = (props) => {
5046
`)
5147

5248
return (
53-
<StyledCallout
49+
<CalloutBanner
5450
{...props}
51+
mx={0}
52+
my={16}
5553
image={getImage(image)!}
5654
alt={t("page-staking-image-alt")}
5755
titleKey={"page-staking-join-community"}
@@ -95,7 +93,7 @@ const StakingCommunityCallout: React.FC<IProps> = (props) => {
9593
<Translation id="rollup-component-website" />
9694
</StyledButtonLink>
9795
</ButtonContainer>
98-
</StyledCallout>
96+
</CalloutBanner>
9997
)
10098
}
10199

0 commit comments

Comments
 (0)