Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 4 additions & 4 deletions apps/dashboard/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -67,7 +67,7 @@
"input-otp": "^1.4.1",
"ioredis": "^5.6.0",
"ipaddr.js": "^2.2.0",
"lucide-react": "0.479.0",
"lucide-react": "0.482.0",
"next": "15.2.2",
"next-plausible": "^3.12.4",
"next-themes": "^0.4.6",
Expand Down Expand Up @@ -105,10 +105,10 @@
},
"devDependencies": {
"@chakra-ui/cli": "^2.4.1",
"@chromatic-com/storybook": "3.2.5",
"@chromatic-com/storybook": "3.2.6",
"@next/bundle-analyzer": "15.2.2",
"@next/eslint-plugin-next": "15.2.2",
"@playwright/test": "1.51.0",
"@playwright/test": "1.51.1",
"@storybook/addon-essentials": "8.6.4",
"@storybook/addon-interactions": "8.6.4",
"@storybook/addon-links": "8.6.4",
Expand All @@ -135,7 +135,7 @@
"eslint": "8.57.0",
"eslint-config-biome": "1.9.4",
"eslint-plugin-react-compiler": "19.0.0-beta-40c6c23-20250301",
"eslint-plugin-storybook": "0.11.4",
"eslint-plugin-storybook": "0.11.6",
"knip": "5.46.0",
"next-sitemap": "^4.2.3",
"postcss": "8.5.3",
Expand Down
4 changes: 2 additions & 2 deletions apps/dashboard/src/@/components/ui/code/getCodeHtml.tsx
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
import * as parserBabel from "prettier/plugins/babel";
import * as estree from "prettier/plugins/estree";
import { format } from "prettier/standalone";
import { type BundledLanguage, codeToHtml } from "shiki";

Expand All @@ -21,10 +20,11 @@ export async function getCodeHtml(
ignoreFormattingErrors?: boolean;
},
) {
const estreePlugin = await import("prettier/plugins/estree");
const formattedCode = isPrettierSupportedLang(lang)
? await format(code, {
parser: "babel-ts",
plugins: [parserBabel, estree],
plugins: [parserBabel, estreePlugin.default],
printWidth: 60,
}).catch((e) => {
if (!options?.ignoreFormattingErrors) {
Expand Down
2 changes: 1 addition & 1 deletion apps/login/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@
"class-variance-authority": "^0.7.1",
"clsx": "^2.1.1",
"jose": "6.0.10",
"lucide-react": "0.479.0",
"lucide-react": "0.482.0",
"next": "15.2.2",
"next-themes": "^0.4.6",
"react": "19.0.0",
Expand Down
4 changes: 2 additions & 2 deletions apps/playground-web/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -36,12 +36,12 @@
"class-variance-authority": "^0.7.1",
"clsx": "^2.1.1",
"jose": "6.0.10",
"lucide-react": "0.479.0",
"lucide-react": "0.482.0",
"next": "15.2.2",
"next-themes": "^0.4.6",
"nextjs-toploader": "^1.6.12",
"openapi-types": "^12.1.3",
"prettier": "3.3.3",
"prettier": "3.5.3",
"react": "19.0.0",
"react-dom": "19.0.0",
"react-hook-form": "7.54.2",
Expand Down
5 changes: 3 additions & 2 deletions apps/playground-web/src/components/code/getCodeHtml.tsx
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
import * as parserBabel from "prettier/plugins/babel";
import * as estree from "prettier/plugins/estree";
import { format } from "prettier/standalone";
import { type BundledLanguage, codeToHtml } from "shiki";

Expand All @@ -15,10 +14,12 @@ function isPrettierSupportedLang(lang: BundledLanguage) {
}

export async function getCodeHtml(code: string, lang: BundledLanguage) {
const estreePlugin = await import("prettier/plugins/estree");

const formattedCode = isPrettierSupportedLang(lang)
? await format(code, {
parser: "babel-ts",
plugins: [parserBabel, estree],
plugins: [parserBabel, estreePlugin.default],
printWidth: 60,
}).catch(() => {
return code;
Expand Down
4 changes: 2 additions & 2 deletions apps/portal/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -35,13 +35,13 @@
"flexsearch": "^0.7.43",
"github-slugger": "^2.0.0",
"he": "^1.2.0",
"lucide-react": "0.479.0",
"lucide-react": "0.482.0",
"next": "15.2.2",
"nextjs-toploader": "^1.6.12",
"node-html-markdown": "^1.3.0",
"node-html-parser": "^6.1.13",
"posthog-js": "1.67.1",
"prettier": "3.3.3",
"prettier": "3.5.3",
"react": "19.0.0",
"react-dom": "19.0.0",
"react-html-parser": "2.0.2",
Expand Down
4 changes: 2 additions & 2 deletions apps/portal/src/components/Document/Code.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,6 @@ import "server-only";
import { cn } from "@/lib/utils";
import Link from "next/link";
import * as parserBabel from "prettier/plugins/babel";
import * as estree from "prettier/plugins/estree";
// prettier
import { format } from "prettier/standalone";
import {
Expand Down Expand Up @@ -54,9 +53,10 @@ export async function CodeBlock(props: {
// format code
if (jsOrTsLangs.has(lang)) {
try {
const estreePlugin = await import("prettier/plugins/estree");
code = await format(code, {
parser: "babel-ts",
plugins: [parserBabel, estree],
plugins: [parserBabel, estreePlugin.default],
printWidth: 70,
});
} catch (_e) {
Expand Down
2 changes: 1 addition & 1 deletion apps/wallet-ui/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@
"class-variance-authority": "^0.7.1",
"clsx": "^2.1.1",
"cmdk": "^1.0.4",
"lucide-react": "0.479.0",
"lucide-react": "0.482.0",
"next": "15.2.2",
"next-themes": "^0.4.6",
"react": "19.0.0",
Expand Down
80 changes: 21 additions & 59 deletions packages/thirdweb/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -132,63 +132,25 @@
},
"typesVersions": {
"*": {
"adapters/*": [
"./dist/types/exports/adapters/*.d.ts"
],
"auth": [
"./dist/types/exports/auth.d.ts"
],
"chains": [
"./dist/types/exports/chains.d.ts"
],
"contract": [
"./dist/types/exports/contract.d.ts"
],
"deploys": [
"./dist/types/exports/deploys.d.ts"
],
"event": [
"./dist/types/exports/event.d.ts"
],
"extensions/*": [
"./dist/types/exports/extensions/*.d.ts"
],
"pay": [
"./dist/types/exports/pay.d.ts"
],
"react": [
"./dist/types/exports/react.d.ts"
],
"react-native": [
"./dist/types/exports/react-native.d.ts"
],
"rpc": [
"./dist/types/exports/rpc.d.ts"
],
"storage": [
"./dist/types/exports/storage.d.ts"
],
"transaction": [
"./dist/types/exports/transaction.d.ts"
],
"utils": [
"./dist/types/exports/utils.d.ts"
],
"wallets": [
"./dist/types/exports/wallets.d.ts"
],
"wallets/*": [
"./dist/types/exports/wallets/*.d.ts"
],
"modules": [
"./dist/types/exports/modules.d.ts"
],
"social": [
"./dist/types/exports/social.d.ts"
],
"ai": [
"./dist/types/exports/ai.d.ts"
]
"adapters/*": ["./dist/types/exports/adapters/*.d.ts"],
"auth": ["./dist/types/exports/auth.d.ts"],
"chains": ["./dist/types/exports/chains.d.ts"],
"contract": ["./dist/types/exports/contract.d.ts"],
"deploys": ["./dist/types/exports/deploys.d.ts"],
"event": ["./dist/types/exports/event.d.ts"],
"extensions/*": ["./dist/types/exports/extensions/*.d.ts"],
"pay": ["./dist/types/exports/pay.d.ts"],
"react": ["./dist/types/exports/react.d.ts"],
"react-native": ["./dist/types/exports/react-native.d.ts"],
"rpc": ["./dist/types/exports/rpc.d.ts"],
"storage": ["./dist/types/exports/storage.d.ts"],
"transaction": ["./dist/types/exports/transaction.d.ts"],
"utils": ["./dist/types/exports/utils.d.ts"],
"wallets": ["./dist/types/exports/wallets.d.ts"],
"wallets/*": ["./dist/types/exports/wallets/*.d.ts"],
"modules": ["./dist/types/exports/modules.d.ts"],
"social": ["./dist/types/exports/social.d.ts"],
"ai": ["./dist/types/exports/ai.d.ts"]
}
},
"browser": {
Expand Down Expand Up @@ -333,7 +295,7 @@
"@aws-sdk/client-lambda": "3.592.0",
"@aws-sdk/credential-providers": "3.592.0",
"@biomejs/biome": "1.9.4",
"@chromatic-com/storybook": "3.2.5",
"@chromatic-com/storybook": "3.2.6",
"@codspeed/vitest-plugin": "4.0.0",
"@coinbase/wallet-mobile-sdk": "1.1.2",
"@mobile-wallet-protocol/client": "0.1.2",
Expand Down Expand Up @@ -363,7 +325,7 @@
"happy-dom": "17.1.8",
"knip": "5.46.0",
"msw": "2.7.3",
"prettier": "3.3.3",
"prettier": "3.5.3",
"react": "19.0.0",
"react-dom": "19.0.0",
"react-native": "0.76.6",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -97,6 +97,13 @@ export function isAddSessionKeySupported(availableSelectors: string[]) {
* @param currentPermissions - The current permissions of the session key.
* @param newPermissions - The new permissions to set for the session key.
* @returns A boolean indicating if the session key should be updated.
* @extension ERC4337
* @example
* ```ts
* import { shouldUpdateSessionKey } from "thirdweb/extensions/erc4337";
*
* const shouldUpdate = await shouldUpdateSessionKey({ accountContract, sessionKeyAddress, newPermissions });
* ```
*/
export async function shouldUpdateSessionKey(args: {
accountContract: ThirdwebContract;
Expand Down
Loading