Skip to content

Commit b42bbde

Browse files
committed
Merge remote-tracking branch 'upstream/dev' into aggregate-fix-links
2 parents 41f4a49 + d01b93f commit b42bbde

File tree

37 files changed

+400
-298
lines changed

37 files changed

+400
-298
lines changed

app/[locale]/_components/home.tsx

Lines changed: 18 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -13,6 +13,7 @@ import type {
1313
} from "@/lib/types"
1414
import { CommunityEvent } from "@/lib/interfaces"
1515

16+
import BannerNotification from "@/components/Banners/BannerNotification"
1617
import { ChevronNext } from "@/components/Chevron"
1718
import CodeModal from "@/components/CodeModal"
1819
import HomeHero from "@/components/Hero/HomeHero"
@@ -24,7 +25,6 @@ import Calendar from "@/components/icons/calendar.svg"
2425
import CalendarAdd from "@/components/icons/calendar-add.svg"
2526
import { Image } from "@/components/Image"
2627
import MainArticle from "@/components/MainArticle"
27-
import { TranslatathonBanner } from "@/components/Translatathon/TranslatathonBanner"
2828
import {
2929
Accordion,
3030
AccordionContent,
@@ -118,7 +118,18 @@ const HomePage = ({
118118

119119
return (
120120
<MainArticle className="flex w-full flex-col items-center" dir={dir}>
121-
<TranslatathonBanner />
121+
<BannerNotification shouldShow>
122+
<p>
123+
Let&apos;s celebrate 10 years of Ethereum! How did ethereum change
124+
your life? -{" "}
125+
<Link
126+
href="https://ethereumstory.paperform.co/"
127+
className="text-white"
128+
>
129+
share your story
130+
</Link>
131+
</p>
132+
</BannerNotification>
122133
<HomeHero heroImg={Hero} className="w-full" />
123134
<div className="w-full space-y-32 px-4 md:mx-6 lg:space-y-48">
124135
<div className="my-20 grid w-full grid-cols-2 gap-x-4 gap-y-8 md:grid-cols-4 md:gap-x-10">
@@ -249,6 +260,11 @@ const HomePage = ({
249260
href="/resources/"
250261
isSecondary
251262
variant="outline"
263+
customEventOptions={{
264+
eventCategory: eventCategory,
265+
eventAction: "ethereum_activity",
266+
eventName: "ethereum_activity",
267+
}}
252268
>
253269
{t("page-index:page-index-activity-action")} <ChevronNext />
254270
</ButtonLink>

app/[locale]/resources/_components/resources.tsx

Lines changed: 140 additions & 99 deletions
Original file line numberDiff line numberDiff line change
@@ -13,6 +13,7 @@ import { ResourceItem, ResourcesContainer } from "@/components/Resources"
1313
import { useResources } from "@/components/Resources/useResources"
1414
import Translation from "@/components/Translation"
1515
import { ButtonLink } from "@/components/ui/buttons/Button"
16+
import { Stack, VStack } from "@/components/ui/flex"
1617
import Link from "@/components/ui/Link"
1718
import { Section } from "@/components/ui/section"
1819

@@ -23,11 +24,12 @@ import { GITHUB_REPO_URL } from "@/lib/constants"
2324
import { useActiveHash } from "@/hooks/useActiveHash"
2425
import { useTranslation } from "@/hooks/useTranslation"
2526
import heroImg from "@/public/images/heroes/guides-hub-hero.jpg"
26-
2727
interface ResourcesPageProps {
2828
txCostsMedianUsd: MetricReturnData
2929
}
3030

31+
const EVENT_CATEGORY = "dashboard"
32+
3133
const ResourcesPage = ({ txCostsMedianUsd }: ResourcesPageProps) => {
3234
const { t } = useTranslation("page-resources")
3335
const resourceSections = useResources({ txCostsMedianUsd })
@@ -46,6 +48,11 @@ const ResourcesPage = ({ txCostsMedianUsd }: ResourcesPageProps) => {
4648
GITHUB_REPO_URL
4749
).toString()}
4850
className="visited:text-white"
51+
customEventOptions={{
52+
eventCategory: EVENT_CATEGORY,
53+
eventAction: "links",
54+
eventName: "Ethereum.org Github Page Feedback",
55+
}}
4956
>
5057
{t("page-resources-share-feedback")}
5158
</Link>
@@ -57,112 +64,146 @@ const ResourcesPage = ({ txCostsMedianUsd }: ResourcesPageProps) => {
5764
description={t("page-resources-hero-description")}
5865
heroImg={heroImg}
5966
/>
60-
61-
<div className="sticky top-1 my-8 flex flex-col items-center gap-3 py-4 text-center md:top-6 md:px-2">
62-
<div className="my-2 text-body-medium">
63-
{t("page-resources-whats-on-this-page")}
64-
</div>
65-
<nav className="z-sticky mx-4 flex max-w-full gap-1 overflow-x-auto bg-background p-2 shadow md:max-w-[calc(100%-2rem)] md:rounded-2xl md:border md:p-0.5 md:shadow-lg">
66-
{resourceSections.map(({ key, title, icon }) => (
67-
<ButtonLink
68-
key={key}
69-
href={`#${key}`}
70-
variant="ghost"
71-
isSecondary
72-
className={cn(
73-
"relative text-nowrap rounded-xl px-4 py-2 text-sm [&_svg]:shrink-0 [&_svg]:text-sm",
74-
activeSection === key && "!text-primary"
75-
)}
76-
>
77-
{activeSection === key && (
78-
<motion.div
79-
layoutId="active-section-highlight"
80-
className="absolute inset-0 z-0 rounded-xl bg-primary-low-contrast"
81-
/>
82-
)}
83-
{icon && <span className="z-10 text-lg">{icon}</span>}
84-
<span className="relative z-10">{title}</span>
85-
</ButtonLink>
86-
))}
87-
</nav>
88-
</div>
89-
90-
{resourceSections.map(({ key, icon, title: sectionTitle, boxes }) => (
91-
<section id={key} key={key} className="mb-16 scroll-mt-40">
92-
<div className="group flex w-full items-center gap-3 border-b bg-transparent px-4 py-6">
93-
<div className="grid size-12 place-items-center rounded-lg border border-border-low-contrast text-2xl [&_svg]:shrink-0">
94-
{icon || <StackIcon />}
95-
</div>
96-
<h2 className="flex-1 text-start font-black">{sectionTitle}</h2>
67+
<Stack className="gap-4 px-2 py-6 md:gap-8 md:px-4 lg:px-8 xl:gap-11">
68+
<div className="sticky top-5 flex flex-col items-center gap-3 text-center md:top-6 md:px-2">
69+
<div className="my-2 text-body-medium">
70+
{t("page-resources-whats-on-this-page")}
9771
</div>
98-
<div className="grid grid-cols-1 gap-8 px-4 pb-12 pt-8 md:pb-12 md:pt-8 lg:grid-cols-2">
99-
{boxes.map(({ title, metric, items, className }) => (
100-
<div
72+
<nav className="z-sticky mx-4 flex max-w-full gap-1 overflow-x-auto bg-background p-2 shadow md:max-w-[calc(100%-2rem)] md:rounded-2xl md:border md:p-0.5 md:shadow-lg">
73+
{resourceSections.map(({ key, title, icon }) => (
74+
<ButtonLink
75+
key={key}
76+
href={`#${key}`}
77+
variant="ghost"
78+
isSecondary
10179
className={cn(
102-
"overflow-hidden rounded-2xl border shadow-lg",
103-
className
80+
"relative text-nowrap rounded-xl px-4 py-2 text-sm [&_svg]:shrink-0 [&_svg]:text-sm",
81+
activeSection === key && "!text-primary"
10482
)}
105-
key={title}
83+
customEventOptions={{
84+
eventCategory: EVENT_CATEGORY,
85+
eventAction: "whats_on_this_page",
86+
eventName: key,
87+
}}
10688
>
107-
<div className="border-b bg-[#ffffff] px-6 py-4 font-bold dark:bg-[#171717]">
108-
{title}
89+
{activeSection === key && (
90+
<motion.div
91+
layoutId="active-section-highlight"
92+
className="absolute inset-0 z-0 rounded-xl bg-primary-low-contrast"
93+
/>
94+
)}
95+
{icon && <span className="z-10 text-lg">{icon}</span>}
96+
<span className="relative z-10">{title}</span>
97+
</ButtonLink>
98+
))}
99+
</nav>
100+
</div>
101+
<Stack className="gap-11 pt-12 md:gap-16 lg:gap-24">
102+
{resourceSections.map(({ key, icon, title: sectionTitle, boxes }) => (
103+
<Stack key={key} asChild>
104+
<section id={key} className="scroll-mt-40 gap-8 md:gap-6">
105+
<div className="group flex w-full items-center gap-4 border-b bg-transparent px-2 py-4">
106+
<div className="grid size-12 place-items-center rounded-lg border border-border-low-contrast text-2xl [&_svg]:shrink-0">
107+
{icon || <StackIcon />}
108+
</div>
109+
<h2 className="flex-1 text-start font-black">
110+
{sectionTitle}
111+
</h2>
109112
</div>
110-
<div className="h-full bg-background bg-gradient-to-br from-white to-primary/10 px-2 py-6 dark:from-transparent dark:to-primary/10">
111-
{metric && metric}
112-
<ResourcesContainer>
113-
{items.map((item) => (
114-
<ResourceItem item={item} key={item.title} />
115-
))}
116-
</ResourcesContainer>
113+
<div className="grid grid-cols-1 gap-8 lg:grid-cols-2 lg:gap-y-6">
114+
{boxes.map(({ title, metric, items, className }) => (
115+
<div
116+
className={cn(
117+
"overflow-hidden rounded-2xl border shadow-lg",
118+
className
119+
)}
120+
key={title}
121+
>
122+
<div className="border-b bg-[#ffffff] px-6 py-4 font-bold dark:bg-[#171717]">
123+
{title}
124+
</div>
125+
<div className="h-full bg-background bg-gradient-to-br from-white to-primary/10 px-2 py-6 dark:from-transparent dark:to-primary/10">
126+
{metric && metric}
127+
<ResourcesContainer>
128+
{items.map((item) => (
129+
<ResourceItem item={item} key={item.title} />
130+
))}
131+
</ResourcesContainer>
132+
</div>
133+
</div>
134+
))}
117135
</div>
118-
</div>
119-
))}
120-
</div>
121-
</section>
122-
))}
123-
124-
<div className="mb-20 text-center">
125-
<Translation id="page-resources:page-resources-find-more" />
126-
</div>
136+
</section>
137+
</Stack>
138+
))}
139+
</Stack>
127140

128-
<Section
129-
id="contribute"
130-
className={cn(
131-
"before:absolute before:-inset-px before:bottom-0 before:z-hide before:rounded-[calc(theme(borderRadius.4xl)+1px)] before:content-['']", // Border/gradient positioning
132-
"before:bg-gradient-to-b before:from-primary-hover/[0.24] before:to-primary-hover/[0.08] before:dark:from-primary-hover/40 before:dark:to-primary-hover/20", // Border/gradient coloring
133-
"relative inset-0 rounded-4xl bg-background" // Paint background color over card portion
134-
)}
135-
>
136-
<div className="mb-12 flex flex-col gap-y-8 rounded-4xl bg-radial-a px-8 py-12 lg:mb-32 xl:mb-36">
137-
<div className="flex flex-col gap-y-4 text-center">
138-
<h2>{t("page-resources-contribute-title")}</h2>
139-
<p>{t("page-resources-contribute-description")}</p>
140-
</div>
141-
<div className="mx-auto grid grid-cols-1 gap-16 md:grid-cols-2">
142-
{/* TODO: Add issue template for resource listing and redirect to new template */}
143-
<ButtonLink
144-
href={new URL(
145-
"issues/new?template=feature_request.yaml",
146-
GITHUB_REPO_URL
147-
).toString()}
148-
variant="outline"
149-
isSecondary
150-
>
151-
{t("page-resources-suggest-resource")}
152-
</ButtonLink>
153-
<ButtonLink
154-
href={new URL(
155-
"issues/new?template=bug_report.yaml",
156-
GITHUB_REPO_URL
157-
).toString()}
158-
variant="outline"
159-
isSecondary
160-
>
161-
<FaGithub /> {t("page-resources-found-bug")}
162-
</ButtonLink>
141+
<VStack className="gap-4 py-16">
142+
<div className="text-center font-bold">
143+
<Translation id="page-resources:page-resources-find-more" />
163144
</div>
164-
</div>
165-
</Section>
145+
<ButtonLink
146+
href="https://ethereumdashboards.com"
147+
size="lg"
148+
customEventOptions={{
149+
eventCategory: EVENT_CATEGORY,
150+
eventAction: "links",
151+
eventName: "ethereumdashboards.com",
152+
}}
153+
>
154+
ethereumdashboards.com
155+
</ButtonLink>
156+
</VStack>
157+
158+
<Section
159+
id="contribute"
160+
className="relative rounded-4xl border border-body/5 bg-background"
161+
>
162+
<VStack className="rounded-4xl bg-radial-a px-4 py-6 md:py-12">
163+
<Stack className="max-w-xl gap-y-10 py-6 lg:max-w-[700px]">
164+
<div className="flex flex-col gap-y-4 text-center">
165+
<h2>{t("page-resources-contribute-title")}</h2>
166+
<p className="text-lg">
167+
{t("page-resources-contribute-description")}
168+
</p>
169+
</div>
170+
<div className="mx-auto grid grid-cols-1 gap-x-3 gap-y-4 md:grid-cols-2">
171+
{/* TODO: Add issue template for resource listing and redirect to new template */}
172+
<ButtonLink
173+
href={new URL(
174+
"issues/new?template=feature_request.yaml",
175+
GITHUB_REPO_URL
176+
).toString()}
177+
variant="outline"
178+
isSecondary
179+
customEventOptions={{
180+
eventCategory: EVENT_CATEGORY,
181+
eventAction: "links",
182+
eventName: "Ethereum.org Github Feature Request",
183+
}}
184+
>
185+
{t("page-resources-suggest-resource")}
186+
</ButtonLink>
187+
<ButtonLink
188+
href={new URL(
189+
"issues/new?template=bug_report.yaml",
190+
GITHUB_REPO_URL
191+
).toString()}
192+
variant="outline"
193+
isSecondary
194+
customEventOptions={{
195+
eventCategory: EVENT_CATEGORY,
196+
eventAction: "links",
197+
eventName: "Ethereum.org Github Bug Report",
198+
}}
199+
>
200+
<FaGithub /> {t("page-resources-found-bug")}
201+
</ButtonLink>
202+
</div>
203+
</Stack>
204+
</VStack>
205+
</Section>
206+
</Stack>
166207
</MainArticle>
167208
)
168209
}

public/content/developers/docs/programming-languages/python/index.md

Lines changed: 13 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -19,31 +19,40 @@ Need a more basic primer first? Check out [ethereum.org/learn](/learn/) or [ethe
1919
- [Understanding Smart Contracts](https://kauri.io/article/e4f66c6079e74a4a9b532148d3158188/ethereum-101-part-5-the-smart-contract)
2020
- [Write your First Smart Contract](https://kauri.io/article/124b7db1d0cf4f47b414f8b13c9d66e2/remix-ide-your-first-smart-contract)
2121
- [Learn How to Compile and Deploy Solidity](https://kauri.io/article/973c5f54c4434bb1b0160cff8c695369/understanding-smart-contract-compilation-and-deployment)
22+
- [The state of Python in blockchain 2023 report](https://tradingstrategy.ai/blog/the-state-of-python-in-blockchain-in-2023)
2223

2324
## Beginner articles {#beginner-articles}
2425

26+
- [web3.py Overview](https://web3py.readthedocs.io/en/latest/overview.html)
27+
- [Ethereum Python Ecosystem Tour](https://snakecharmers.ethereum.org/python-ecosystem/)
2528
- [A (Python) Developer's Guide to Ethereum](https://snakecharmers.ethereum.org/a-developers-guide-to-ethereum-pt-1/)
26-
- [The state of Python in blockchain 2023 report](https://tradingstrategy.ai/blog/the-state-of-python-in-blockchain-in-2023)
29+
- [Prize-Worthy: An Ethereum Python Hackathon Guide](https://snakecharmers.ethereum.org/prize-worthy/)
2730
- [An Introduction to Smart Contracts with Vyper](https://kauri.io/#collections/Getting%20Started/an-introduction-to-smart-contracts-with-vyper/)
28-
- [Deploy your own ERC20 Token with Python and Brownie](https://betterprogramming.pub/python-blockchain-token-deployment-tutorial-create-an-erc20-77a5fd2e1a58)
2931
- [How to develop Ethereum contract using Python Flask?](https://medium.com/coinmonks/how-to-develop-ethereum-contract-using-python-flask-9758fe65976e)
3032
- [Intro to Web3.py · Ethereum For Python Developers](https://www.dappuniversity.com/articles/web3-py-intro)
3133
- [How to call a Smart Contract function using Python and web3.py](https://stackoverflow.com/questions/57580702/how-to-call-a-smart-contract-function-using-python-and-web3-py)
3234

3335
## Intermediate articles {#intermediate-articles}
3436

37+
- [Friends of web3.py: Intro to Ape](https://snakecharmers.ethereum.org/intro-to-ape/)
3538
- [Dapp Development for Python Programmers](https://levelup.gitconnected.com/dapps-development-for-python-developers-f52b32b54f28)
3639
- [Creating a Python Ethereum Interface: Part 1](https://hackernoon.com/creating-a-python-ethereum-interface-part-1-4d2e47ea0f4d)
3740
- [Ethereum Smart Contracts in Python: a comprehensive(ish) guide](https://hackernoon.com/ethereum-smart-contracts-in-python-a-comprehensive-ish-guide-771b03990988)
38-
- [Using Brownie and Python to deploy Smart Contracts](https://dev.to/patrickalphac/using-brownie-for-to-deploy-smart-contracts-1kkp)
39-
- [Creating NFTs on OpenSea with Brownie](https://www.freecodecamp.org/news/how-to-make-an-nft-and-render-on-opensea-marketplace/)
4041

4142
## Advanced use patterns {#advanced-use-patterns}
4243

44+
- [web3.py Patterns: Real-Time Event Subscriptions](https://snakecharmers.ethereum.org/subscriptions/)
45+
- [web3.py Patterns: WebSocketProvider](https://snakecharmers.ethereum.org/websocketprovider/)
4346
- [Compiling, deploying and calling Ethereum smartcontract using Python](https://yohanes.gultom.id/2018/11/28/compiling-deploying-and-calling-ethereum-smartcontract-using-python/)
4447
- [Analyze Solidity Smart Contracts with Slither](https://kauri.io/#collections/DevOps/analyze-solidity-smart-contracts-with-slither/#analyze-solidity-smart-contracts-with-slither)
4548
- [Blockchain Fintech Tutorial: Lending and Borrowing With Python](https://blog.chain.link/blockchain-fintech-defi-tutorial-lending-borrowing-python/)
4649

50+
## Archived articles
51+
52+
- [Deploy your own ERC20 Token with Python and Brownie](https://betterprogramming.pub/python-blockchain-token-deployment-tutorial-create-an-erc20-77a5fd2e1a58)
53+
- [Using Brownie and Python to deploy Smart Contracts](https://dev.to/patrickalphac/using-brownie-for-to-deploy-smart-contracts-1kkp)
54+
- [Creating NFTs on OpenSea with Brownie](https://www.freecodecamp.org/news/how-to-make-an-nft-and-render-on-opensea-marketplace/)
55+
4756
## Python projects and tools {#python-projects-and-tools}
4857

4958
### Active: {#active}

public/content/developers/tutorials/hello-world-smart-contract-fullstack/index.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -664,7 +664,7 @@ Successfully verified contract HelloWorld on Etherscan.
664664
https://goerli.etherscan.io/address/<contract-address>#contracts
665665
```
666666

667-
Congrats! Your smart contract code is on Etherescan!
667+
Congrats! Your smart contract code is on Etherscan!
668668

669669
### Check out your smart contract on Etherscan! {#check-out-your-smart-contract-on-etherscan}
670670

public/content/translations/es/developers/tutorials/hello-world-smart-contract-fullstack/index.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -661,7 +661,7 @@ Successfully verified contract HelloWorld on Etherscan.
661661
https://goerli.etherscan.io/address/<contract-address>#contracts
662662
```
663663

664-
¡Felicidades! ¡Su código de contrato inteligente está en Etherescan!
664+
¡Felicidades! ¡Su código de contrato inteligente está en Etherscan!
665665

666666
### ¡Eche un vistazo a su contrato inteligente en Etherscan! {#check-out-your-smart-contract-on-etherscan}
667667

0 commit comments

Comments
 (0)