Skip to content

Commit f31a56c

Browse files
authored
Merge pull request #10729 from ethereum/dev
Release candidate 7.17.1
2 parents 7bb1cc7 + 78c876e commit f31a56c

File tree

395 files changed

+3885
-3537
lines changed

Some content is hidden

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

395 files changed

+3885
-3537
lines changed

.all-contributorsrc

Lines changed: 54 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -10285,6 +10285,60 @@
1028510285
"contributions": [
1028610286
"ideas"
1028710287
]
10288+
},
10289+
{
10290+
"login": "SahityaRoy",
10291+
"name": "Sahitya Roy",
10292+
"avatar_url": "https://avatars.githubusercontent.com/u/72821604?v=4",
10293+
"profile": "https://www.linkedin.com/in/sahitya-roy-244b941a2/",
10294+
"contributions": [
10295+
"ideas"
10296+
]
10297+
},
10298+
{
10299+
"login": "Keecointoken",
10300+
"name": "KeeCoin",
10301+
"avatar_url": "https://avatars.githubusercontent.com/u/99338330?v=4",
10302+
"profile": "https://www.keecoin.io",
10303+
"contributions": [
10304+
"ideas"
10305+
]
10306+
},
10307+
{
10308+
"login": "tomatowax",
10309+
"name": "Seungwook Chi",
10310+
"avatar_url": "https://avatars.githubusercontent.com/u/799503?v=4",
10311+
"profile": "http://www.tomatowax.com/",
10312+
"contributions": [
10313+
"content"
10314+
]
10315+
},
10316+
{
10317+
"login": "0xx92",
10318+
"name": "0xx92",
10319+
"avatar_url": "https://avatars.githubusercontent.com/u/133748557?v=4",
10320+
"profile": "https://github.com/0xx92",
10321+
"contributions": [
10322+
"content"
10323+
]
10324+
},
10325+
{
10326+
"login": "altinocoelho",
10327+
"name": "altinocoelho",
10328+
"avatar_url": "https://avatars.githubusercontent.com/u/92543849?v=4",
10329+
"profile": "https://github.com/altinocoelho",
10330+
"contributions": [
10331+
"content"
10332+
]
10333+
},
10334+
{
10335+
"login": "viac92",
10336+
"name": "viac92",
10337+
"avatar_url": "https://avatars.githubusercontent.com/u/64146594?v=4",
10338+
"profile": "https://github.com/viac92",
10339+
"contributions": [
10340+
"content"
10341+
]
1028810342
}
1028910343
],
1029010344
"contributorsPerLine": 7,

.github/workflows/get-crowdin-contributors.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@ jobs:
2222

2323
- name: Install ts-node
2424
run: yarn global add ts-node
25-
25+
2626
- name: Set up git
2727
run: |
2828
git config --global user.email "[email protected]"

README.md

Lines changed: 8 additions & 0 deletions

package.json

Lines changed: 7 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "ethereum-org-website",
3-
"version": "7.17.0",
3+
"version": "7.17.1",
44
"description": "Website of ethereum.org",
55
"main": "index.js",
66
"repository": "[email protected]:ethereum/ethereum-org-website.git",
@@ -17,6 +17,7 @@
1717
"@emotion/styled": "^11.9.3",
1818
"@formatjs/intl-locale": "^2.4.14",
1919
"@formatjs/intl-numberformat": "^6.1.4",
20+
"@googleapis/calendar": "^6.0.0",
2021
"@mdx-js/mdx": "^1.6.5",
2122
"@mdx-js/react": "^1.6.5",
2223
"algoliasearch": "^4.3.0",
@@ -55,6 +56,7 @@
5556
"gatsby-transformer-json": "^5.4.0",
5657
"gatsby-transformer-remark": "^6.4.0",
5758
"gatsby-transformer-sharp": "^5.4.0",
59+
"googleapis": "^118.0.0",
5860
"htmr": "^1.0.2",
5961
"i18next": "^21.9.2",
6062
"is-relative-url": "^3.0.0",
@@ -105,6 +107,7 @@
105107
"babel-loader": "^8.3.0",
106108
"babel-preset-gatsby": "^2.23.0",
107109
"chromatic": "^6.19.9",
110+
"cross-env": "^7.0.3",
108111
"github-slugger": "^1.3.0",
109112
"gray-matter": "^4.0.3",
110113
"husky": "^4.2.5",
@@ -122,8 +125,8 @@
122125
"scripts": {
123126
"postinstall": "yarn theme",
124127
"build": "gatsby build",
125-
"build:lambda": "NODE_OPTIONS=--openssl-legacy-provider netlify-lambda build src/lambda --config=./webpack.lambda.js",
126-
"build:10gb": "NODE_OPTIONS=--max-old-space-size=10240 gatsby build",
128+
"build:lambda": "cross-env NODE_OPTIONS=--openssl-legacy-provider netlify-lambda build src/lambda --config=./webpack.lambda.js",
129+
"build:10gb": "cross-env NODE_OPTIONS=--max-old-space-size=10240 gatsby build",
127130
"clean": "gatsby clean",
128131
"crowdin-clean": "rm -rf .crowdin && mkdir .crowdin",
129132
"crowdin-import": "ts-node src/scripts/crowdin-import.ts",
@@ -132,6 +135,7 @@
132135
"generate-heading-ids": "ts-node -O '{ \"module\": \"commonjs\" }' src/scripts/generateHeadingIds.ts",
133136
"unused-translations": "ts-node -O '{ \"module\": \"commonjs\" }' src/scripts/unusedTranslations.ts",
134137
"reorg-intl": "ts-node -O '{ \"module\": \"commonjs\" }' src/scripts/reorgIntlFiles.ts",
138+
"optimize-images": "ts-node -O '{ \"module\": \"commonjs\" }' src/scripts/optimizeImages.ts",
135139
"crowdin-contributors": "ts-node -O '{ \"module\": \"commonjs\" }' src/scripts/crowdin/getCrowdinContributors.ts",
136140
"start": "gatsby develop",
137141
"start:lambda": "netlify-lambda serve src/lambda",
Lines changed: 93 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,93 @@
1+
import {
2+
createMultiStyleConfigHelpers,
3+
cssVar,
4+
defineStyle,
5+
getToken,
6+
} from "@chakra-ui/react"
7+
import { avatarAnatomy } from "@chakra-ui/anatomy"
8+
import { avatarDefaultTheme, defineMergeStyles } from "./components.utils"
9+
import { pick } from "lodash"
10+
11+
const { defineMultiStyleConfig, definePartsStyle } =
12+
createMultiStyleConfigHelpers(avatarAnatomy.keys)
13+
14+
const { baseStyle: defaultBaseStyle, sizes: defaultSizes } = avatarDefaultTheme
15+
16+
const $border = cssVar("avatar-border-color", "transparent")
17+
const $mlBySize = cssVar("ml-by-size")
18+
19+
const baseStyleContainer = defineStyle((props) => {
20+
const primaryLowContrast = getToken(
21+
"colors",
22+
"primary.lowContrast"
23+
)(props.theme)
24+
25+
return defineMergeStyles(defaultBaseStyle?.(props).container, {
26+
[$border.variable]: "transparent",
27+
borderWidth: "1px",
28+
"&:hover, [data-peer]:hover ~ &": {
29+
boxShadow: `0.15em 0.15em 0 ${primaryLowContrast}`,
30+
},
31+
_focus: {
32+
outline: "4px solid",
33+
outlineColor: "primary.hover",
34+
outlineOffset: "-1px",
35+
},
36+
_active: {
37+
[$border.variable]: "colors.primary.hover",
38+
boxShadow: "none",
39+
"& img": {
40+
opacity: 0.7,
41+
},
42+
},
43+
"[role='group'] &": {
44+
[$border.variable]: "colors.background.base",
45+
_notLast: {
46+
marginLeft: $mlBySize.reference,
47+
},
48+
},
49+
})
50+
})
51+
52+
const baseStyleExessLabel = defineStyle((props) =>
53+
defineMergeStyles(defaultBaseStyle?.(props).excessLabel, {
54+
bg: "body.base",
55+
color: "background.base",
56+
ms: $mlBySize.reference,
57+
})
58+
)
59+
60+
const baseStyle = definePartsStyle((props) => ({
61+
container: baseStyleContainer(props),
62+
excessLabel: baseStyleExessLabel(props),
63+
}))
64+
65+
const USED_SIZES = ["xs", "sm", "md", "lg"] as const
66+
67+
const pickedDefaultSizes: { [k in (typeof USED_SIZES)[number]]?: object } =
68+
pick(defaultSizes, ...USED_SIZES)
69+
70+
const sizes = defineMergeStyles(pickedDefaultSizes, {
71+
xs: {
72+
group: {
73+
[$mlBySize.variable]: "space.-1",
74+
},
75+
excessLabel: {
76+
fontSize: "0.563rem",
77+
},
78+
},
79+
sm: {
80+
group: {
81+
[$mlBySize.variable]: "space.-2",
82+
},
83+
excessLabel: {
84+
fontSize: "sm",
85+
},
86+
},
87+
})
88+
89+
export const Avatar = defineMultiStyleConfig({
90+
baseStyle,
91+
// @ts-expect-error
92+
sizes,
93+
})

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

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,4 @@
1+
import { Avatar } from "./Avatar"
12
import { Badge } from "./Badge"
23
import { Button } from "./Button"
34
import { Link } from "./Link"
@@ -12,7 +13,6 @@ import { Switch } from "./Switch"
1213
import { Input } from "./Input"
1314
import {
1415
accordionDefaultTheme,
15-
avatarDefaultTheme,
1616
breadcrumbDefaultTheme,
1717
closeButtonDefaultTheme,
1818
codeDefaultTheme,
@@ -28,7 +28,7 @@ import {
2828

2929
export default {
3030
Accordion: accordionDefaultTheme,
31-
Avatar: avatarDefaultTheme,
31+
Avatar,
3232
Badge,
3333
Breadcrumb: breadcrumbDefaultTheme,
3434
Button,

src/@chakra-ui/gatsby-plugin/semanticTokens.ts

Lines changed: 0 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -101,12 +101,6 @@ const semanticTokens = {
101101
"linear-gradient(102.7deg, rgba(185, 185, 241, 0.2) 0%, rgba(84, 132, 234, 0.2) 51.56%, rgba(58, 142, 137, 0.2) 100%)",
102102
},
103103
},
104-
shadows: {
105-
buttonHover: {
106-
_light: "4px 4px 0 var(--eth-colors-blue-100)",
107-
_dark: "4px 4px 0 #352313",
108-
},
109-
},
110104
}
111105

112106
export default semanticTokens

src/api/calendarEvents.ts

Lines changed: 17 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,17 @@
1+
import type { GatsbyFunctionRequest, GatsbyFunctionResponse } from "gatsby"
2+
import { lambda } from "../lambda/calendarEvents"
3+
4+
async function handler(
5+
__req: GatsbyFunctionRequest,
6+
res: GatsbyFunctionResponse
7+
): Promise<void> {
8+
// passing env vars as arguments due to a bug on GC functions where env vars
9+
// can not be accessed by imported functions
10+
const { statusCode, body } = await lambda(
11+
process.env.GOOGLE_API_KEY!,
12+
process.env.GOOGLE_CALENDAR_ID!
13+
)
14+
res.status(statusCode).send(body)
15+
}
16+
17+
export default handler

src/assets/assets/eth-diamond-black-gray.png

100755100644
-127 KB

src/assets/assets/eth-diamond-black-white.jpg

100755100644
-69.8 KB

0 commit comments

Comments
 (0)