Skip to content

Commit e268f65

Browse files
committed
Merge branch 'main' of https://github.com/thirdweb-dev/js into gi/portal-translation-crowdinai
2 parents 528e359 + 1616b7f commit e268f65

File tree

93 files changed

+5050
-4640
lines changed

Some content is hidden

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

93 files changed

+5050
-4640
lines changed

.changeset/friendly-lamps-think.md

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

.changeset/ninety-maps-sparkle.md

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
---
2+
"thirdweb": patch
3+
---
4+
5+
export `randomPrivateKey` from `thirdweb/wallets`

.changeset/short-carrots-smile.md

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

.changeset/tasty-berries-ring.md

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,7 @@
1+
---
2+
"@thirdweb-dev/service-utils": patch
3+
"@thirdweb-dev/wagmi-adapter": patch
4+
"thirdweb": patch
5+
---
6+
7+
updated dependencies

.github/pull_request_template.md

Lines changed: 6 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,12 +1,15 @@
1-
---
2-
title: "[SDK/Dashboard/Portal] Feature/Fix: Concise title for the changes"
3-
---
1+
<!--
2+
3+
## title your PR with this format: "[SDK/Dashboard/Portal] Feature/Fix: Concise title for the changes"
44
55
If you did not copy the branch name from Linear, paste the issue tag here (format is TEAM-0000):
66
77
## Notes for the reviewer
8+
89
Anything important to call out? Be sure to also clarify these in your comments.
910
1011
## How to test
12+
1113
Unit tests, playground, etc.
1214
15+
-->

apps/dashboard/package.json

Lines changed: 38 additions & 38 deletions
Original file line numberDiff line numberDiff line change
@@ -31,29 +31,29 @@
3131
"@marsidev/react-turnstile": "^1.1.0",
3232
"@n8tb1t/use-scroll-position": "^2.0.3",
3333
"@radix-ui/react-accordion": "^1.2.2",
34-
"@radix-ui/react-alert-dialog": "^1.1.4",
34+
"@radix-ui/react-alert-dialog": "^1.1.5",
3535
"@radix-ui/react-avatar": "^1.1.2",
3636
"@radix-ui/react-checkbox": "^1.1.3",
37-
"@radix-ui/react-dialog": "1.1.4",
38-
"@radix-ui/react-dropdown-menu": "^2.1.3",
39-
"@radix-ui/react-hover-card": "^1.1.3",
37+
"@radix-ui/react-dialog": "1.1.5",
38+
"@radix-ui/react-dropdown-menu": "^2.1.5",
39+
"@radix-ui/react-hover-card": "^1.1.5",
4040
"@radix-ui/react-label": "^2.1.1",
41-
"@radix-ui/react-popover": "^1.1.3",
41+
"@radix-ui/react-popover": "^1.1.5",
4242
"@radix-ui/react-progress": "^1.1.1",
4343
"@radix-ui/react-radio-group": "^1.2.2",
44-
"@radix-ui/react-select": "^2.1.3",
44+
"@radix-ui/react-select": "^2.1.5",
4545
"@radix-ui/react-separator": "^1.1.1",
4646
"@radix-ui/react-slot": "^1.1.1",
4747
"@radix-ui/react-switch": "^1.1.2",
48-
"@radix-ui/react-tooltip": "1.1.5",
49-
"@sentry/nextjs": "8.45.1",
50-
"@shazow/whatsabi": "^0.18.0",
51-
"@tanstack/react-query": "5.62.16",
48+
"@radix-ui/react-tooltip": "1.1.7",
49+
"@sentry/nextjs": "8.51.0",
50+
"@shazow/whatsabi": "^0.19.0",
51+
"@tanstack/react-query": "5.65.0",
5252
"@tanstack/react-table": "^8.20.6",
5353
"@thirdweb-dev/service-utils": "workspace:*",
5454
"@vercel/functions": "^1.5.2",
55-
"@vercel/og": "^0.6.4",
56-
"abitype": "1.0.7",
55+
"@vercel/og": "^0.6.5",
56+
"abitype": "1.0.8",
5757
"chakra-react-select": "^4.7.6",
5858
"class-variance-authority": "^0.7.1",
5959
"clsx": "^2.1.1",
@@ -62,19 +62,19 @@
6262
"date-fns": "4.1.0",
6363
"fetch-event-stream": "0.1.5",
6464
"flat": "^6.0.1",
65-
"framer-motion": "11.15.0",
65+
"framer-motion": "12.0.6",
6666
"fuse.js": "7.0.0",
6767
"input-otp": "^1.4.1",
6868
"ioredis": "^5.4.1",
6969
"ipaddr.js": "^2.2.0",
70-
"lucide-react": "0.468.0",
71-
"next": "15.1.3",
70+
"lucide-react": "0.474.0",
71+
"next": "15.1.6",
7272
"next-plausible": "^3.12.4",
7373
"next-themes": "^0.4.4",
7474
"nextjs-toploader": "^1.6.12",
7575
"openapi-types": "^12.1.3",
7676
"p-limit": "^6.2.0",
77-
"papaparse": "^5.4.1",
77+
"papaparse": "^5.5.1",
7878
"pluralize": "^8.0.0",
7979
"posthog-js": "1.67.1",
8080
"qrcode": "^1.5.3",
@@ -87,11 +87,11 @@
8787
"react-hook-form": "7.54.2",
8888
"react-markdown": "^9.0.1",
8989
"react-table": "^7.8.0",
90-
"recharts": "2.14.1",
90+
"recharts": "2.15.1",
9191
"remark-gfm": "^4.0.0",
9292
"server-only": "^0.0.1",
9393
"shiki": "1.27.0",
94-
"sonner": "^1.7.1",
94+
"sonner": "^1.7.2",
9595
"spdx-correct": "^3.2.0",
9696
"swagger-ui-react": "^5.18.2",
9797
"tailwind-merge": "^2.6.0",
@@ -103,29 +103,29 @@
103103
},
104104
"devDependencies": {
105105
"@chakra-ui/cli": "^2.4.1",
106-
"@chromatic-com/storybook": "3.2.2",
107-
"@next/bundle-analyzer": "15.1.0",
108-
"@next/eslint-plugin-next": "15.1.3",
109-
"@playwright/test": "1.49.1",
110-
"@storybook/addon-essentials": "8.4.7",
111-
"@storybook/addon-interactions": "8.4.7",
112-
"@storybook/addon-links": "8.4.7",
113-
"@storybook/addon-onboarding": "8.4.7",
114-
"@storybook/addon-viewport": "8.4.7",
115-
"@storybook/blocks": "8.4.7",
116-
"@storybook/nextjs": "8.4.7",
117-
"@storybook/react": "8.5.0",
118-
"@storybook/test": "8.4.7",
106+
"@chromatic-com/storybook": "3.2.4",
107+
"@next/bundle-analyzer": "15.1.6",
108+
"@next/eslint-plugin-next": "15.1.6",
109+
"@playwright/test": "1.50.0",
110+
"@storybook/addon-essentials": "8.5.2",
111+
"@storybook/addon-interactions": "8.5.2",
112+
"@storybook/addon-links": "8.5.2",
113+
"@storybook/addon-onboarding": "8.5.2",
114+
"@storybook/addon-viewport": "8.5.2",
115+
"@storybook/blocks": "8.5.2",
116+
"@storybook/nextjs": "8.5.2",
117+
"@storybook/react": "8.5.2",
118+
"@storybook/test": "8.5.2",
119119
"@types/color": "4.2.0",
120-
"@types/node": "22.10.2",
120+
"@types/node": "22.10.10",
121121
"@types/papaparse": "^5.3.15",
122122
"@types/pluralize": "^0.0.33",
123123
"@types/qrcode": "^1.5.5",
124-
"@types/react": "19.0.2",
124+
"@types/react": "19.0.8",
125125
"@types/react-dom": "19.0.3",
126126
"@types/react-table": "^7.7.20",
127127
"@types/spdx-correct": "^3.1.3",
128-
"@types/swagger-ui-react": "^4.18.3",
128+
"@types/swagger-ui-react": "^4.19.0",
129129
"@typescript-eslint/eslint-plugin": "7.14.1",
130130
"@typescript-eslint/parser": "7.14.1",
131131
"autoprefixer": "^10.4.19",
@@ -134,11 +134,11 @@
134134
"eslint-config-biome": "1.9.4",
135135
"eslint-plugin-react-compiler": "19.0.0-beta-df7b47d-20241124",
136136
"eslint-plugin-storybook": "^0.11.1",
137-
"knip": "5.41.0",
137+
"knip": "5.43.5",
138138
"next-sitemap": "^4.2.3",
139-
"postcss": "8.4.49",
140-
"storybook": "8.4.7",
139+
"postcss": "8.5.1",
140+
"storybook": "8.5.2",
141141
"tailwindcss": "3.4.17",
142-
"typescript": "5.7.2"
142+
"typescript": "5.7.3"
143143
}
144144
}

apps/dashboard/src/@/api/team.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,7 @@ export type Team = {
2525
billingPlan: "pro" | "growth" | "free" | "starter";
2626
billingStatus: "validPayment" | (string & {}) | null;
2727
billingEmail: string | null;
28-
growthTrialEligible: boolean | null;
28+
growthTrialEligible: false;
2929
enabledScopes: EnabledTeamScope[];
3030
};
3131

apps/dashboard/src/@/components/blocks/NetworkSelectors.tsx

Lines changed: 18 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -16,6 +16,8 @@ type Option = { label: string; value: string };
1616
export function MultiNetworkSelector(props: {
1717
selectedChainIds: number[];
1818
onChange: (chainIds: number[]) => void;
19+
disableChainId?: boolean;
20+
className?: string;
1921
}) {
2022
const { allChains, idToChain } = useAllChainsData();
2123

@@ -53,16 +55,24 @@ export function MultiNetworkSelector(props: {
5355
return (
5456
<div className="flex justify-between gap-4">
5557
<span className="flex grow gap-2 truncate text-left">
58+
<ChainIcon
59+
className="size-5"
60+
ipfsSrc={chain.icon?.url}
61+
loading="lazy"
62+
/>
5663
{cleanChainName(chain.name)}
5764
</span>
58-
<Badge variant="outline" className="gap-2">
59-
<span className="text-muted-foreground">Chain ID</span>
60-
{chain.chainId}
61-
</Badge>
65+
66+
{!props.disableChainId && (
67+
<Badge variant="outline" className="gap-2">
68+
<span className="text-muted-foreground">Chain ID</span>
69+
{chain.chainId}
70+
</Badge>
71+
)}
6272
</div>
6373
);
6474
},
65-
[idToChain],
75+
[idToChain, props.disableChainId],
6676
);
6777

6878
return (
@@ -79,6 +89,7 @@ export function MultiNetworkSelector(props: {
7989
disabled={allChains.length === 0}
8090
overrideSearchFn={searchFn}
8191
renderOption={renderOption}
92+
className={props.className}
8293
/>
8394
);
8495
}
@@ -143,7 +154,7 @@ export function SingleNetworkSelector(props: {
143154
ipfsSrc={chain.icon?.url}
144155
loading="lazy"
145156
/>
146-
{chain.name}
157+
{cleanChainName(chain.name)}
147158
</span>
148159

149160
{!props.disableChainId && (
@@ -168,6 +179,7 @@ export function SingleNetworkSelector(props: {
168179
onValueChange={(chainId) => {
169180
props.onChange(Number(chainId));
170181
}}
182+
closeOnSelect={true}
171183
placeholder={isLoadingChains ? "Loading Chains..." : "Select Chain"}
172184
overrideSearchFn={searchFn}
173185
renderOption={renderOption}

apps/dashboard/src/@/components/blocks/select-with-search.tsx

Lines changed: 8 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -33,6 +33,7 @@ interface SelectWithSearchProps
3333
popoverContentClassName?: string;
3434
side?: "left" | "right" | "top" | "bottom";
3535
align?: "center" | "start" | "end";
36+
closeOnSelect?: boolean;
3637
}
3738

3839
export const SelectWithSearch = React.forwardRef<
@@ -50,6 +51,7 @@ export const SelectWithSearch = React.forwardRef<
5051
overrideSearchFn,
5152
popoverContentClassName,
5253
searchPlaceholder,
54+
closeOnSelect,
5355
...props
5456
},
5557
ref,
@@ -177,7 +179,12 @@ export const SelectWithSearch = React.forwardRef<
177179
key={option.value}
178180
role="option"
179181
aria-selected={isSelected}
180-
onClick={() => onValueChange(option.value)}
182+
onClick={() => {
183+
onValueChange(option.value);
184+
if (closeOnSelect) {
185+
setIsPopoverOpen(false);
186+
}
187+
}}
181188
variant="ghost"
182189
className="flex w-full cursor-pointer justify-start gap-3 rounded-sm px-3 py-2 text-left"
183190
ref={

apps/dashboard/src/@3rdweb-sdk/react/hooks/useEngine.ts

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@ import {
1010
import type { ResultItem } from "app/team/[team_slug]/(team)/~/engine/(instance)/[engineId]/metrics/components/StatusCodes";
1111
import type { EngineBackendWalletType } from "lib/engine";
1212
import { useState } from "react";
13-
import { useActiveAccount, useActiveWalletChain } from "thirdweb/react";
13+
import { useActiveAccount } from "thirdweb/react";
1414
import invariant from "tiny-invariant";
1515
import type { EngineStatus } from "../../../app/team/[team_slug]/(team)/~/engine/(instance)/[engineId]/overview/components/transactions-table";
1616
import { engineKeys } from "../cache-keys";
@@ -469,12 +469,12 @@ export function useEngineBackendWalletBalance(params: {
469469
instanceUrl: string;
470470
address: string;
471471
authToken: string;
472+
chainId: number;
472473
}) {
473-
const { instanceUrl, address, authToken } = params;
474-
const chainId = useActiveWalletChain()?.id;
474+
const { instanceUrl, address, authToken, chainId } = params;
475475

476476
return useQuery({
477-
queryKey: engineKeys.backendWalletBalance(address, chainId || 1),
477+
queryKey: engineKeys.backendWalletBalance(address, chainId),
478478
queryFn: async () => {
479479
invariant(chainId, "chainId is required");
480480

0 commit comments

Comments
 (0)