From 740af55fce440e74fe40993775a09947951f9032 Mon Sep 17 00:00:00 2001 From: smgv Date: Fri, 1 Nov 2024 13:24:25 +0530 Subject: [PATCH 1/3] solidja initial setup --- package-lock.json | 1094 ++++++++++++++++++++++++-- package.json | 1 + packages/modal-ui/.eslintrc.json | 32 + packages/modal-ui/.gitignore | 2 + packages/modal-ui/README.md | 34 + packages/modal-ui/index.html | 15 + packages/modal-ui/package.json | 48 ++ packages/modal-ui/postcss.config.js | 7 + packages/modal-ui/src/App.tsx | 20 + packages/modal-ui/src/index.css | 3 + packages/modal-ui/src/index.tsx | 14 + packages/modal-ui/tailwind.config.ts | 292 +++++++ packages/modal-ui/tsconfig.json | 23 + packages/modal-ui/vite.config.ts | 20 + packages/modal-ui/webpack.config.js | 73 ++ 15 files changed, 1619 insertions(+), 59 deletions(-) create mode 100644 packages/modal-ui/.eslintrc.json create mode 100644 packages/modal-ui/.gitignore create mode 100644 packages/modal-ui/README.md create mode 100644 packages/modal-ui/index.html create mode 100644 packages/modal-ui/package.json create mode 100644 packages/modal-ui/postcss.config.js create mode 100644 packages/modal-ui/src/App.tsx create mode 100644 packages/modal-ui/src/index.css create mode 100644 packages/modal-ui/src/index.tsx create mode 100644 packages/modal-ui/tailwind.config.ts create mode 100644 packages/modal-ui/tsconfig.json create mode 100644 packages/modal-ui/vite.config.ts create mode 100644 packages/modal-ui/webpack.config.js diff --git a/package-lock.json b/package-lock.json index 403ffb739..ecddb4021 100644 --- a/package-lock.json +++ b/package-lock.json @@ -13,6 +13,7 @@ "packages/composables/*", "packages/hooks/*", "packages/modal", + "packages/modal-ui", "packages/no-modal", "packages/plugins/*", "packages/providers/*", @@ -1869,6 +1870,374 @@ "tslib": "^2.4.0" } }, + "node_modules/@esbuild/aix-ppc64": { + "version": "0.21.5", + "resolved": "https://registry.npmjs.org/@esbuild/aix-ppc64/-/aix-ppc64-0.21.5.tgz", + "integrity": "sha512-1SDgH6ZSPTlggy1yI6+Dbkiz8xzpHJEVAlF/AM1tHPLsf5STom9rwtjE4hKAF20FfXXNTFqEYXyJNWh1GiZedQ==", + "cpu": [ + "ppc64" + ], + "dev": true, + "optional": true, + "os": [ + "aix" + ], + "engines": { + "node": ">=12" + } + }, + "node_modules/@esbuild/android-arm": { + "version": "0.21.5", + "resolved": "https://registry.npmjs.org/@esbuild/android-arm/-/android-arm-0.21.5.tgz", + "integrity": "sha512-vCPvzSjpPHEi1siZdlvAlsPxXl7WbOVUBBAowWug4rJHb68Ox8KualB+1ocNvT5fjv6wpkX6o/iEpbDrf68zcg==", + "cpu": [ + "arm" + ], + "dev": true, + "optional": true, + "os": [ + "android" + ], + "engines": { + "node": ">=12" + } + }, + "node_modules/@esbuild/android-arm64": { + "version": "0.21.5", + "resolved": "https://registry.npmjs.org/@esbuild/android-arm64/-/android-arm64-0.21.5.tgz", + "integrity": "sha512-c0uX9VAUBQ7dTDCjq+wdyGLowMdtR/GoC2U5IYk/7D1H1JYC0qseD7+11iMP2mRLN9RcCMRcjC4YMclCzGwS/A==", + "cpu": [ + "arm64" + ], + "dev": true, + "optional": true, + "os": [ + "android" + ], + "engines": { + "node": ">=12" + } + }, + "node_modules/@esbuild/android-x64": { + "version": "0.21.5", + "resolved": "https://registry.npmjs.org/@esbuild/android-x64/-/android-x64-0.21.5.tgz", + "integrity": "sha512-D7aPRUUNHRBwHxzxRvp856rjUHRFW1SdQATKXH2hqA0kAZb1hKmi02OpYRacl0TxIGz/ZmXWlbZgjwWYaCakTA==", + "cpu": [ + "x64" + ], + "dev": true, + "optional": true, + "os": [ + "android" + ], + "engines": { + "node": ">=12" + } + }, + "node_modules/@esbuild/darwin-arm64": { + "version": "0.21.5", + "resolved": "https://registry.npmjs.org/@esbuild/darwin-arm64/-/darwin-arm64-0.21.5.tgz", + "integrity": "sha512-DwqXqZyuk5AiWWf3UfLiRDJ5EDd49zg6O9wclZ7kUMv2WRFr4HKjXp/5t8JZ11QbQfUS6/cRCKGwYhtNAY88kQ==", + "cpu": [ + "arm64" + ], + "dev": true, + "optional": true, + "os": [ + "darwin" + ], + "engines": { + "node": ">=12" + } + }, + "node_modules/@esbuild/darwin-x64": { + "version": "0.21.5", + "resolved": "https://registry.npmjs.org/@esbuild/darwin-x64/-/darwin-x64-0.21.5.tgz", + "integrity": "sha512-se/JjF8NlmKVG4kNIuyWMV/22ZaerB+qaSi5MdrXtd6R08kvs2qCN4C09miupktDitvh8jRFflwGFBQcxZRjbw==", + "cpu": [ + "x64" + ], + "dev": true, + "optional": true, + "os": [ + "darwin" + ], + "engines": { + "node": ">=12" + } + }, + "node_modules/@esbuild/freebsd-arm64": { + "version": "0.21.5", + "resolved": "https://registry.npmjs.org/@esbuild/freebsd-arm64/-/freebsd-arm64-0.21.5.tgz", + "integrity": "sha512-5JcRxxRDUJLX8JXp/wcBCy3pENnCgBR9bN6JsY4OmhfUtIHe3ZW0mawA7+RDAcMLrMIZaf03NlQiX9DGyB8h4g==", + "cpu": [ + "arm64" + ], + "dev": true, + "optional": true, + "os": [ + "freebsd" + ], + "engines": { + "node": ">=12" + } + }, + "node_modules/@esbuild/freebsd-x64": { + "version": "0.21.5", + "resolved": "https://registry.npmjs.org/@esbuild/freebsd-x64/-/freebsd-x64-0.21.5.tgz", + "integrity": "sha512-J95kNBj1zkbMXtHVH29bBriQygMXqoVQOQYA+ISs0/2l3T9/kj42ow2mpqerRBxDJnmkUDCaQT/dfNXWX/ZZCQ==", + "cpu": [ + "x64" + ], + "dev": true, + "optional": true, + "os": [ + "freebsd" + ], + "engines": { + "node": ">=12" + } + }, + "node_modules/@esbuild/linux-arm": { + "version": "0.21.5", + "resolved": "https://registry.npmjs.org/@esbuild/linux-arm/-/linux-arm-0.21.5.tgz", + "integrity": "sha512-bPb5AHZtbeNGjCKVZ9UGqGwo8EUu4cLq68E95A53KlxAPRmUyYv2D6F0uUI65XisGOL1hBP5mTronbgo+0bFcA==", + "cpu": [ + "arm" + ], + "dev": true, + "optional": true, + "os": [ + "linux" + ], + "engines": { + "node": ">=12" + } + }, + "node_modules/@esbuild/linux-arm64": { + "version": "0.21.5", + "resolved": "https://registry.npmjs.org/@esbuild/linux-arm64/-/linux-arm64-0.21.5.tgz", + "integrity": "sha512-ibKvmyYzKsBeX8d8I7MH/TMfWDXBF3db4qM6sy+7re0YXya+K1cem3on9XgdT2EQGMu4hQyZhan7TeQ8XkGp4Q==", + "cpu": [ + "arm64" + ], + "dev": true, + "optional": true, + "os": [ + "linux" + ], + "engines": { + "node": ">=12" + } + }, + "node_modules/@esbuild/linux-ia32": { + "version": "0.21.5", + "resolved": "https://registry.npmjs.org/@esbuild/linux-ia32/-/linux-ia32-0.21.5.tgz", + "integrity": "sha512-YvjXDqLRqPDl2dvRODYmmhz4rPeVKYvppfGYKSNGdyZkA01046pLWyRKKI3ax8fbJoK5QbxblURkwK/MWY18Tg==", + "cpu": [ + "ia32" + ], + "dev": true, + "optional": true, + "os": [ + "linux" + ], + "engines": { + "node": ">=12" + } + }, + "node_modules/@esbuild/linux-loong64": { + "version": "0.21.5", + "resolved": "https://registry.npmjs.org/@esbuild/linux-loong64/-/linux-loong64-0.21.5.tgz", + "integrity": "sha512-uHf1BmMG8qEvzdrzAqg2SIG/02+4/DHB6a9Kbya0XDvwDEKCoC8ZRWI5JJvNdUjtciBGFQ5PuBlpEOXQj+JQSg==", + "cpu": [ + "loong64" + ], + "dev": true, + "optional": true, + "os": [ + "linux" + ], + "engines": { + "node": ">=12" + } + }, + "node_modules/@esbuild/linux-mips64el": { + "version": "0.21.5", + "resolved": "https://registry.npmjs.org/@esbuild/linux-mips64el/-/linux-mips64el-0.21.5.tgz", + "integrity": "sha512-IajOmO+KJK23bj52dFSNCMsz1QP1DqM6cwLUv3W1QwyxkyIWecfafnI555fvSGqEKwjMXVLokcV5ygHW5b3Jbg==", + "cpu": [ + "mips64el" + ], + "dev": true, + "optional": true, + "os": [ + "linux" + ], + "engines": { + "node": ">=12" + } + }, + "node_modules/@esbuild/linux-ppc64": { + "version": "0.21.5", + "resolved": "https://registry.npmjs.org/@esbuild/linux-ppc64/-/linux-ppc64-0.21.5.tgz", + "integrity": "sha512-1hHV/Z4OEfMwpLO8rp7CvlhBDnjsC3CttJXIhBi+5Aj5r+MBvy4egg7wCbe//hSsT+RvDAG7s81tAvpL2XAE4w==", + "cpu": [ + "ppc64" + ], + "dev": true, + "optional": true, + "os": [ + "linux" + ], + "engines": { + "node": ">=12" + } + }, + "node_modules/@esbuild/linux-riscv64": { + "version": "0.21.5", + "resolved": "https://registry.npmjs.org/@esbuild/linux-riscv64/-/linux-riscv64-0.21.5.tgz", + "integrity": "sha512-2HdXDMd9GMgTGrPWnJzP2ALSokE/0O5HhTUvWIbD3YdjME8JwvSCnNGBnTThKGEB91OZhzrJ4qIIxk/SBmyDDA==", + "cpu": [ + "riscv64" + ], + "dev": true, + "optional": true, + "os": [ + "linux" + ], + "engines": { + "node": ">=12" + } + }, + "node_modules/@esbuild/linux-s390x": { + "version": "0.21.5", + "resolved": "https://registry.npmjs.org/@esbuild/linux-s390x/-/linux-s390x-0.21.5.tgz", + "integrity": "sha512-zus5sxzqBJD3eXxwvjN1yQkRepANgxE9lgOW2qLnmr8ikMTphkjgXu1HR01K4FJg8h1kEEDAqDcZQtbrRnB41A==", + "cpu": [ + "s390x" + ], + "dev": true, + "optional": true, + "os": [ + "linux" + ], + "engines": { + "node": ">=12" + } + }, + "node_modules/@esbuild/linux-x64": { + "version": "0.21.5", + "resolved": "https://registry.npmjs.org/@esbuild/linux-x64/-/linux-x64-0.21.5.tgz", + "integrity": "sha512-1rYdTpyv03iycF1+BhzrzQJCdOuAOtaqHTWJZCWvijKD2N5Xu0TtVC8/+1faWqcP9iBCWOmjmhoH94dH82BxPQ==", + "cpu": [ + "x64" + ], + "dev": true, + "optional": true, + "os": [ + "linux" + ], + "engines": { + "node": ">=12" + } + }, + "node_modules/@esbuild/netbsd-x64": { + "version": "0.21.5", + "resolved": "https://registry.npmjs.org/@esbuild/netbsd-x64/-/netbsd-x64-0.21.5.tgz", + "integrity": "sha512-Woi2MXzXjMULccIwMnLciyZH4nCIMpWQAs049KEeMvOcNADVxo0UBIQPfSmxB3CWKedngg7sWZdLvLczpe0tLg==", + "cpu": [ + "x64" + ], + "dev": true, + "optional": true, + "os": [ + "netbsd" + ], + "engines": { + "node": ">=12" + } + }, + "node_modules/@esbuild/openbsd-x64": { + "version": "0.21.5", + "resolved": "https://registry.npmjs.org/@esbuild/openbsd-x64/-/openbsd-x64-0.21.5.tgz", + "integrity": "sha512-HLNNw99xsvx12lFBUwoT8EVCsSvRNDVxNpjZ7bPn947b8gJPzeHWyNVhFsaerc0n3TsbOINvRP2byTZ5LKezow==", + "cpu": [ + "x64" + ], + "dev": true, + "optional": true, + "os": [ + "openbsd" + ], + "engines": { + "node": ">=12" + } + }, + "node_modules/@esbuild/sunos-x64": { + "version": "0.21.5", + "resolved": "https://registry.npmjs.org/@esbuild/sunos-x64/-/sunos-x64-0.21.5.tgz", + "integrity": "sha512-6+gjmFpfy0BHU5Tpptkuh8+uw3mnrvgs+dSPQXQOv3ekbordwnzTVEb4qnIvQcYXq6gzkyTnoZ9dZG+D4garKg==", + "cpu": [ + "x64" + ], + "dev": true, + "optional": true, + "os": [ + "sunos" + ], + "engines": { + "node": ">=12" + } + }, + "node_modules/@esbuild/win32-arm64": { + "version": "0.21.5", + "resolved": "https://registry.npmjs.org/@esbuild/win32-arm64/-/win32-arm64-0.21.5.tgz", + "integrity": "sha512-Z0gOTd75VvXqyq7nsl93zwahcTROgqvuAcYDUr+vOv8uHhNSKROyU961kgtCD1e95IqPKSQKH7tBTslnS3tA8A==", + "cpu": [ + "arm64" + ], + "dev": true, + "optional": true, + "os": [ + "win32" + ], + "engines": { + "node": ">=12" + } + }, + "node_modules/@esbuild/win32-ia32": { + "version": "0.21.5", + "resolved": "https://registry.npmjs.org/@esbuild/win32-ia32/-/win32-ia32-0.21.5.tgz", + "integrity": "sha512-SWXFF1CL2RVNMaVs+BBClwtfZSvDgtL//G/smwAc5oVK/UPu2Gu9tIaRgFmYFFKrmg3SyAjSrElf0TiJ1v8fYA==", + "cpu": [ + "ia32" + ], + "dev": true, + "optional": true, + "os": [ + "win32" + ], + "engines": { + "node": ">=12" + } + }, + "node_modules/@esbuild/win32-x64": { + "version": "0.21.5", + "resolved": "https://registry.npmjs.org/@esbuild/win32-x64/-/win32-x64-0.21.5.tgz", + "integrity": "sha512-tQd/1efJuzPC6rCFwEvLtci/xNFcTZknmXs98FYDfGE4wP9ClFV98nyKrzJKVPMhdDnjzLhdUyMX4PsQAPjwIw==", + "cpu": [ + "x64" + ], + "dev": true, + "optional": true, + "os": [ + "win32" + ], + "engines": { + "node": ">=12" + } + }, "node_modules/@eslint-community/eslint-utils": { "version": "4.4.0", "dev": true, @@ -3197,6 +3566,12 @@ "node": ">= 8" } }, + "node_modules/@nothing-but/utils": { + "version": "0.12.1", + "resolved": "https://registry.npmjs.org/@nothing-but/utils/-/utils-0.12.1.tgz", + "integrity": "sha512-1qZU1Q5El0IjE7JT/ucvJNzdr2hL3W8Rm27xNf1p6gb3Nw8pGnZmxp6/GEW9h+I1k1cICxXNq25hBwknTQ7yhg==", + "dev": true + }, "node_modules/@npmcli/agent": { "version": "2.2.2", "dev": true, @@ -4816,85 +5191,323 @@ "resolved": "https://registry.npmjs.org/@sindresorhus/merge-streams/-/merge-streams-2.3.0.tgz", "integrity": "sha512-LtoMMhxAlorcGhmFYI+LhPgbPZCkgP6ra1YL604EeF6U98pLlQ3iWIGMdWSC+vWmPBWBNgmDBAhnAobLROJmwg==", "dev": true, - "license": "MIT", - "engines": { - "node": ">=18" + "license": "MIT", + "engines": { + "node": ">=18" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, + "node_modules/@socket.io/component-emitter": { + "version": "3.1.2", + "license": "MIT" + }, + "node_modules/@solana/buffer-layout": { + "version": "4.0.1", + "license": "MIT", + "dependencies": { + "buffer": "~6.0.3" + }, + "engines": { + "node": ">=5.10" + } + }, + "node_modules/@solana/wallet-standard-features": { + "version": "1.2.0", + "license": "Apache-2.0", + "dependencies": { + "@wallet-standard/base": "^1.0.1", + "@wallet-standard/features": "^1.0.3" + }, + "engines": { + "node": ">=16" + } + }, + "node_modules/@solana/web3.js": { + "version": "1.95.4", + "resolved": "https://registry.npmjs.org/@solana/web3.js/-/web3.js-1.95.4.tgz", + "integrity": "sha512-sdewnNEA42ZSMxqkzdwEWi6fDgzwtJHaQa5ndUGEJYtoOnM6X5cvPmjoTUp7/k7bRrVAxfBgDnvQQHD6yhlLYw==", + "license": "MIT", + "dependencies": { + "@babel/runtime": "^7.25.0", + "@noble/curves": "^1.4.2", + "@noble/hashes": "^1.4.0", + "@solana/buffer-layout": "^4.0.1", + "agentkeepalive": "^4.5.0", + "bigint-buffer": "^1.1.5", + "bn.js": "^5.2.1", + "borsh": "^0.7.0", + "bs58": "^4.0.1", + "buffer": "6.0.3", + "fast-stable-stringify": "^1.0.0", + "jayson": "^4.1.1", + "node-fetch": "^2.7.0", + "rpc-websockets": "^9.0.2", + "superstruct": "^2.0.2" + } + }, + "node_modules/@solana/web3.js/node_modules/bs58": { + "version": "4.0.1", + "license": "MIT", + "dependencies": { + "base-x": "^3.0.2" + } + }, + "node_modules/@solana/web3.js/node_modules/node-fetch": { + "version": "2.7.0", + "license": "MIT", + "dependencies": { + "whatwg-url": "^5.0.0" + }, + "engines": { + "node": "4.x || >=6.0.0" + }, + "peerDependencies": { + "encoding": "^0.1.0" + }, + "peerDependenciesMeta": { + "encoding": { + "optional": true + } + } + }, + "node_modules/@solid-devtools/debugger": { + "version": "0.23.4", + "resolved": "https://registry.npmjs.org/@solid-devtools/debugger/-/debugger-0.23.4.tgz", + "integrity": "sha512-EfTB1Eo313wztQYGJ4Ec/wE70Ay2d603VCXfT3RlyqO5QfLrQGRHX5NXC07hJpQTJJJ3tbNgzO7+ZKo76MM5uA==", + "dev": true, + "dependencies": { + "@nothing-but/utils": "~0.12.0", + "@solid-devtools/shared": "^0.13.2", + "@solid-primitives/bounds": "^0.0.118", + "@solid-primitives/cursor": "^0.0.112", + "@solid-primitives/event-bus": "^1.0.8", + "@solid-primitives/event-listener": "^2.3.0", + "@solid-primitives/keyboard": "^1.2.5", + "@solid-primitives/platform": "^0.1.0", + "@solid-primitives/rootless": "^1.4.2", + "@solid-primitives/scheduled": "^1.4.1", + "@solid-primitives/static-store": "^0.0.5", + "@solid-primitives/utils": "^6.2.1" + }, + "peerDependencies": { + "solid-js": "^1.8.0" + } + }, + "node_modules/@solid-devtools/shared": { + "version": "0.13.2", + "resolved": "https://registry.npmjs.org/@solid-devtools/shared/-/shared-0.13.2.tgz", + "integrity": "sha512-Y4uaC4EfTVwBR537MZwfaY/eiWAh+hW4mbtnwNuUw/LFmitHSkQhNQTUlLQv/S0chtwrYWQBxvXos1dC7e8R9g==", + "dev": true, + "dependencies": { + "@solid-primitives/event-bus": "^1.0.8", + "@solid-primitives/event-listener": "^2.3.0", + "@solid-primitives/media": "^2.2.5", + "@solid-primitives/refs": "^1.0.5", + "@solid-primitives/rootless": "^1.4.2", + "@solid-primitives/scheduled": "^1.4.1", + "@solid-primitives/static-store": "^0.0.5", + "@solid-primitives/styles": "^0.0.111", + "@solid-primitives/utils": "^6.2.1" + }, + "peerDependencies": { + "solid-js": "^1.8.0" + } + }, + "node_modules/@solid-primitives/bounds": { + "version": "0.0.118", + "resolved": "https://registry.npmjs.org/@solid-primitives/bounds/-/bounds-0.0.118.tgz", + "integrity": "sha512-Qj42w8LlnhJ3r/t+t0c0vrdwIvvQMPgjEFGmLiwREaA85ojLbgL9lSBq2tKvljeLCvRVkgj10KEUf+vc99VCIg==", + "dev": true, + "dependencies": { + "@solid-primitives/event-listener": "^2.3.0", + "@solid-primitives/resize-observer": "^2.0.22", + "@solid-primitives/static-store": "^0.0.5", + "@solid-primitives/utils": "^6.2.1" + }, + "peerDependencies": { + "solid-js": "^1.6.12" + } + }, + "node_modules/@solid-primitives/cursor": { + "version": "0.0.112", + "resolved": "https://registry.npmjs.org/@solid-primitives/cursor/-/cursor-0.0.112.tgz", + "integrity": "sha512-TAtU7qD7ipSLSXHnq8FhhosAPVX+dnOCb/ITcGcLlj8e/C9YKcxDhgBHJ3R/d1xDRb5/vO/szJtEz6fnQD311Q==", + "dev": true, + "dependencies": { + "@solid-primitives/utils": "^6.2.1" + }, + "peerDependencies": { + "solid-js": "^1.6.12" + } + }, + "node_modules/@solid-primitives/event-bus": { + "version": "1.0.11", + "resolved": "https://registry.npmjs.org/@solid-primitives/event-bus/-/event-bus-1.0.11.tgz", + "integrity": "sha512-bSwVA4aI2aNHomSbEroUnisMSyDDXJbrw4U8kFEvrcYdlLrJX5i6QeCFx+vj/zdQQw62KAllrEIyWP8KMpPVnQ==", + "dev": true, + "dependencies": { + "@solid-primitives/utils": "^6.2.3" + }, + "peerDependencies": { + "solid-js": "^1.6.12" + } + }, + "node_modules/@solid-primitives/event-listener": { + "version": "2.3.3", + "resolved": "https://registry.npmjs.org/@solid-primitives/event-listener/-/event-listener-2.3.3.tgz", + "integrity": "sha512-DAJbl+F0wrFW2xmcV8dKMBhk9QLVLuBSW+TR4JmIfTaObxd13PuL7nqaXnaYKDWOYa6otB00qcCUIGbuIhSUgQ==", + "dev": true, + "dependencies": { + "@solid-primitives/utils": "^6.2.3" + }, + "peerDependencies": { + "solid-js": "^1.6.12" + } + }, + "node_modules/@solid-primitives/keyboard": { + "version": "1.2.8", + "resolved": "https://registry.npmjs.org/@solid-primitives/keyboard/-/keyboard-1.2.8.tgz", + "integrity": "sha512-pJtcbkjozS6L1xvTht9rPpyPpX55nAkfBzbFWdf3y0Suwh6qClTibvvObzKOf7uzQ+8aZRDH4LsoGmbTKXtJjQ==", + "dev": true, + "dependencies": { + "@solid-primitives/event-listener": "^2.3.3", + "@solid-primitives/rootless": "^1.4.5", + "@solid-primitives/utils": "^6.2.3" + }, + "peerDependencies": { + "solid-js": "^1.6.12" + } + }, + "node_modules/@solid-primitives/media": { + "version": "2.2.9", + "resolved": "https://registry.npmjs.org/@solid-primitives/media/-/media-2.2.9.tgz", + "integrity": "sha512-QUmU62D4/d9YWx/4Dvr/UZasIkIpqNXz7wosA5GLmesRW9XlPa3G5M6uOmTw73SByHNTCw0D6x8bSdtvvLgzvQ==", + "dev": true, + "dependencies": { + "@solid-primitives/event-listener": "^2.3.3", + "@solid-primitives/rootless": "^1.4.5", + "@solid-primitives/static-store": "^0.0.8", + "@solid-primitives/utils": "^6.2.3" + }, + "peerDependencies": { + "solid-js": "^1.6.12" + } + }, + "node_modules/@solid-primitives/media/node_modules/@solid-primitives/static-store": { + "version": "0.0.8", + "resolved": "https://registry.npmjs.org/@solid-primitives/static-store/-/static-store-0.0.8.tgz", + "integrity": "sha512-ZecE4BqY0oBk0YG00nzaAWO5Mjcny8Fc06CdbXadH9T9lzq/9GefqcSe/5AtdXqjvY/DtJ5C6CkcjPZO0o/eqg==", + "dev": true, + "dependencies": { + "@solid-primitives/utils": "^6.2.3" + }, + "peerDependencies": { + "solid-js": "^1.6.12" + } + }, + "node_modules/@solid-primitives/platform": { + "version": "0.1.2", + "resolved": "https://registry.npmjs.org/@solid-primitives/platform/-/platform-0.1.2.tgz", + "integrity": "sha512-sSxcZfuUrtxcwV0vdjmGnZQcflACzMfLriVeIIWXKp8hzaS3Or3tO6EFQkTd3L8T5dTq+kTtLvPscXIpL0Wzdg==", + "dev": true, + "peerDependencies": { + "solid-js": "^1.6.12" + } + }, + "node_modules/@solid-primitives/refs": { + "version": "1.0.8", + "resolved": "https://registry.npmjs.org/@solid-primitives/refs/-/refs-1.0.8.tgz", + "integrity": "sha512-+jIsWG8/nYvhaCoG2Vg6CJOLgTmPKFbaCrNQKWfChalgUf9WrVxWw0CdJb3yX15n5lUcQ0jBo6qYtuVVmBLpBw==", + "dev": true, + "dependencies": { + "@solid-primitives/utils": "^6.2.3" }, - "funding": { - "url": "https://github.com/sponsors/sindresorhus" + "peerDependencies": { + "solid-js": "^1.6.12" } }, - "node_modules/@socket.io/component-emitter": { - "version": "3.1.2", - "license": "MIT" - }, - "node_modules/@solana/buffer-layout": { - "version": "4.0.1", - "license": "MIT", + "node_modules/@solid-primitives/resize-observer": { + "version": "2.0.26", + "resolved": "https://registry.npmjs.org/@solid-primitives/resize-observer/-/resize-observer-2.0.26.tgz", + "integrity": "sha512-KbPhwal6ML9OHeUTZszBbt6PYSMj89d4wVCLxlvDYL4U0+p+xlCEaqz6v9dkCwm/0Lb+Wed7W5T1dQZCP3JUUw==", + "dev": true, "dependencies": { - "buffer": "~6.0.3" + "@solid-primitives/event-listener": "^2.3.3", + "@solid-primitives/rootless": "^1.4.5", + "@solid-primitives/static-store": "^0.0.8", + "@solid-primitives/utils": "^6.2.3" }, - "engines": { - "node": ">=5.10" + "peerDependencies": { + "solid-js": "^1.6.12" } }, - "node_modules/@solana/wallet-standard-features": { - "version": "1.2.0", - "license": "Apache-2.0", + "node_modules/@solid-primitives/resize-observer/node_modules/@solid-primitives/static-store": { + "version": "0.0.8", + "resolved": "https://registry.npmjs.org/@solid-primitives/static-store/-/static-store-0.0.8.tgz", + "integrity": "sha512-ZecE4BqY0oBk0YG00nzaAWO5Mjcny8Fc06CdbXadH9T9lzq/9GefqcSe/5AtdXqjvY/DtJ5C6CkcjPZO0o/eqg==", + "dev": true, "dependencies": { - "@wallet-standard/base": "^1.0.1", - "@wallet-standard/features": "^1.0.3" + "@solid-primitives/utils": "^6.2.3" }, - "engines": { - "node": ">=16" + "peerDependencies": { + "solid-js": "^1.6.12" } }, - "node_modules/@solana/web3.js": { - "version": "1.95.4", - "resolved": "https://registry.npmjs.org/@solana/web3.js/-/web3.js-1.95.4.tgz", - "integrity": "sha512-sdewnNEA42ZSMxqkzdwEWi6fDgzwtJHaQa5ndUGEJYtoOnM6X5cvPmjoTUp7/k7bRrVAxfBgDnvQQHD6yhlLYw==", - "license": "MIT", + "node_modules/@solid-primitives/rootless": { + "version": "1.4.5", + "resolved": "https://registry.npmjs.org/@solid-primitives/rootless/-/rootless-1.4.5.tgz", + "integrity": "sha512-GFJE9GC3ojx0aUKqAUZmQPyU8fOVMtnVNrkdk2yS4kd17WqVSpXpoTmo9CnOwA+PG7FTzdIkogvfLQSLs4lrww==", + "dev": true, "dependencies": { - "@babel/runtime": "^7.25.0", - "@noble/curves": "^1.4.2", - "@noble/hashes": "^1.4.0", - "@solana/buffer-layout": "^4.0.1", - "agentkeepalive": "^4.5.0", - "bigint-buffer": "^1.1.5", - "bn.js": "^5.2.1", - "borsh": "^0.7.0", - "bs58": "^4.0.1", - "buffer": "6.0.3", - "fast-stable-stringify": "^1.0.0", - "jayson": "^4.1.1", - "node-fetch": "^2.7.0", - "rpc-websockets": "^9.0.2", - "superstruct": "^2.0.2" + "@solid-primitives/utils": "^6.2.3" + }, + "peerDependencies": { + "solid-js": "^1.6.12" } }, - "node_modules/@solana/web3.js/node_modules/bs58": { - "version": "4.0.1", - "license": "MIT", - "dependencies": { - "base-x": "^3.0.2" + "node_modules/@solid-primitives/scheduled": { + "version": "1.4.4", + "resolved": "https://registry.npmjs.org/@solid-primitives/scheduled/-/scheduled-1.4.4.tgz", + "integrity": "sha512-BTGdFP7t+s7RSak+s1u0eTix4lHP23MrbGkgQTFlt1E+4fmnD/bEx3ZfNW7Grylz3GXgKyXrgDKA7jQ/wuWKgA==", + "dev": true, + "peerDependencies": { + "solid-js": "^1.6.12" } }, - "node_modules/@solana/web3.js/node_modules/node-fetch": { - "version": "2.7.0", - "license": "MIT", + "node_modules/@solid-primitives/static-store": { + "version": "0.0.5", + "resolved": "https://registry.npmjs.org/@solid-primitives/static-store/-/static-store-0.0.5.tgz", + "integrity": "sha512-ssQ+s/wrlFAEE4Zw8GV499yBfvWx7SMm+ZVc11wvao4T5xg9VfXCL9Oa+x4h+vPMvSV/Knv5LrsLiUa+wlJUXQ==", + "dev": true, "dependencies": { - "whatwg-url": "^5.0.0" - }, - "engines": { - "node": "4.x || >=6.0.0" + "@solid-primitives/utils": "^6.2.1" }, "peerDependencies": { - "encoding": "^0.1.0" + "solid-js": "^1.6.12" + } + }, + "node_modules/@solid-primitives/styles": { + "version": "0.0.111", + "resolved": "https://registry.npmjs.org/@solid-primitives/styles/-/styles-0.0.111.tgz", + "integrity": "sha512-1mBxOGAPXmfD5oYCvqjKBDN7SuNjz2qz7RdH7KtsuNLQh6lpuSKadtHnLvru0Y8Vz1InqTJisBIy/6P5kyDmPw==", + "dev": true, + "dependencies": { + "@solid-primitives/rootless": "^1.4.2", + "@solid-primitives/utils": "^6.2.1" }, - "peerDependenciesMeta": { - "encoding": { - "optional": true - } + "peerDependencies": { + "solid-js": "^1.6.12" + } + }, + "node_modules/@solid-primitives/utils": { + "version": "6.2.3", + "resolved": "https://registry.npmjs.org/@solid-primitives/utils/-/utils-6.2.3.tgz", + "integrity": "sha512-CqAwKb2T5Vi72+rhebSsqNZ9o67buYRdEJrIFzRXz3U59QqezuuxPsyzTSVCacwS5Pf109VRsgCJQoxKRoECZQ==", + "dev": true, + "peerDependencies": { + "solid-js": "^1.6.12" } }, "node_modules/@stablelib/aead": { @@ -6051,6 +6664,47 @@ "tslib": "^2.4.0" } }, + "node_modules/@types/babel__core": { + "version": "7.20.5", + "resolved": "https://registry.npmjs.org/@types/babel__core/-/babel__core-7.20.5.tgz", + "integrity": "sha512-qoQprZvz5wQFJwMDqeseRXWv3rqMvhgpbXFfVyWhbx9X47POIA6i/+dXefEmZKoAgOaTdaIgNSMqMIU61yRyzA==", + "dev": true, + "dependencies": { + "@babel/parser": "^7.20.7", + "@babel/types": "^7.20.7", + "@types/babel__generator": "*", + "@types/babel__template": "*", + "@types/babel__traverse": "*" + } + }, + "node_modules/@types/babel__generator": { + "version": "7.6.8", + "resolved": "https://registry.npmjs.org/@types/babel__generator/-/babel__generator-7.6.8.tgz", + "integrity": "sha512-ASsj+tpEDsEiFr1arWrlN6V3mdfjRMZt6LtK/Vp/kreFLnr5QH5+DhvD5nINYZXzwJvXeGq+05iUXcAzVrqWtw==", + "dev": true, + "dependencies": { + "@babel/types": "^7.0.0" + } + }, + "node_modules/@types/babel__template": { + "version": "7.4.4", + "resolved": "https://registry.npmjs.org/@types/babel__template/-/babel__template-7.4.4.tgz", + "integrity": "sha512-h/NUaSyG5EyxBIp8YRxo4RMe2/qQgvyowRwVMzhYhBCONbW8PUsg4lkFMrhgZhUe5z3L3MiLDuvyJ/CaPa2A8A==", + "dev": true, + "dependencies": { + "@babel/parser": "^7.1.0", + "@babel/types": "^7.0.0" + } + }, + "node_modules/@types/babel__traverse": { + "version": "7.20.6", + "resolved": "https://registry.npmjs.org/@types/babel__traverse/-/babel__traverse-7.20.6.tgz", + "integrity": "sha512-r1bzfrm0tomOI8g1SzvCaQHo6Lcv6zu0EA+W2kHrt8dyrHQxGzBBL4kdkzIS+jBMV+EYcMAEAqXqYaLJq5rOZg==", + "dev": true, + "dependencies": { + "@babel/types": "^7.20.7" + } + }, "node_modules/@types/bn.js": { "version": "5.1.6", "resolved": "https://registry.npmjs.org/@types/bn.js/-/bn.js-5.1.6.tgz", @@ -7031,6 +7685,10 @@ "resolved": "packages/hooks/modal-react-hooks", "link": true }, + "node_modules/@web3auth/modal-ui": { + "resolved": "packages/modal-ui", + "link": true + }, "node_modules/@web3auth/modal-vue-composables": { "resolved": "packages/composables/modal-vue-composables", "link": true @@ -8240,6 +8898,35 @@ "url": "https://github.com/sponsors/sindresorhus" } }, + "node_modules/babel-plugin-jsx-dom-expressions": { + "version": "0.39.3", + "resolved": "https://registry.npmjs.org/babel-plugin-jsx-dom-expressions/-/babel-plugin-jsx-dom-expressions-0.39.3.tgz", + "integrity": "sha512-6RzmSu21zYPlV2gNwzjGG9FgODtt9hIWnx7L//OIioIEuRcnpDZoY8Tr+I81Cy1SrH4qoDyKpwHHo6uAMAeyPA==", + "dev": true, + "dependencies": { + "@babel/helper-module-imports": "7.18.6", + "@babel/plugin-syntax-jsx": "^7.18.6", + "@babel/types": "^7.20.7", + "html-entities": "2.3.3", + "parse5": "^7.1.2", + "validate-html-nesting": "^1.2.1" + }, + "peerDependencies": { + "@babel/core": "^7.20.12" + } + }, + "node_modules/babel-plugin-jsx-dom-expressions/node_modules/@babel/helper-module-imports": { + "version": "7.18.6", + "resolved": "https://registry.npmjs.org/@babel/helper-module-imports/-/helper-module-imports-7.18.6.tgz", + "integrity": "sha512-0NFvs3VkuSYbFi1x2Vd6tKrywq+z/cLeYC/RJNFrIX/30Bf5aiGYbtvGXolEktzJH8o5E5KJ3tT+nkxuuZFVlA==", + "dev": true, + "dependencies": { + "@babel/types": "^7.18.6" + }, + "engines": { + "node": ">=6.9.0" + } + }, "node_modules/babel-plugin-polyfill-corejs2": { "version": "0.4.11", "dev": true, @@ -8276,6 +8963,18 @@ "@babel/core": "^7.4.0 || ^8.0.0-0 <8.0.0" } }, + "node_modules/babel-preset-solid": { + "version": "1.9.3", + "resolved": "https://registry.npmjs.org/babel-preset-solid/-/babel-preset-solid-1.9.3.tgz", + "integrity": "sha512-jvlx5wDp8s+bEF9sGFw/84SInXOA51ttkUEroQziKMbxplXThVKt83qB6bDTa1HuLNatdU9FHpFOiQWs1tLQIg==", + "dev": true, + "dependencies": { + "babel-plugin-jsx-dom-expressions": "^0.39.3" + }, + "peerDependencies": { + "@babel/core": "^7.0.0" + } + }, "node_modules/balanced-match": { "version": "1.0.2", "dev": true, @@ -11456,6 +12155,44 @@ "es6-promise": "^4.0.3" } }, + "node_modules/esbuild": { + "version": "0.21.5", + "resolved": "https://registry.npmjs.org/esbuild/-/esbuild-0.21.5.tgz", + "integrity": "sha512-mg3OPMV4hXywwpoDxu3Qda5xCKQi+vCTZq8S9J/EpkhB2HzKXq4SNFZE3+NK93JYxc8VMSep+lOUSC/RVKaBqw==", + "dev": true, + "hasInstallScript": true, + "bin": { + "esbuild": "bin/esbuild" + }, + "engines": { + "node": ">=12" + }, + "optionalDependencies": { + "@esbuild/aix-ppc64": "0.21.5", + "@esbuild/android-arm": "0.21.5", + "@esbuild/android-arm64": "0.21.5", + "@esbuild/android-x64": "0.21.5", + "@esbuild/darwin-arm64": "0.21.5", + "@esbuild/darwin-x64": "0.21.5", + "@esbuild/freebsd-arm64": "0.21.5", + "@esbuild/freebsd-x64": "0.21.5", + "@esbuild/linux-arm": "0.21.5", + "@esbuild/linux-arm64": "0.21.5", + "@esbuild/linux-ia32": "0.21.5", + "@esbuild/linux-loong64": "0.21.5", + "@esbuild/linux-mips64el": "0.21.5", + "@esbuild/linux-ppc64": "0.21.5", + "@esbuild/linux-riscv64": "0.21.5", + "@esbuild/linux-s390x": "0.21.5", + "@esbuild/linux-x64": "0.21.5", + "@esbuild/netbsd-x64": "0.21.5", + "@esbuild/openbsd-x64": "0.21.5", + "@esbuild/sunos-x64": "0.21.5", + "@esbuild/win32-arm64": "0.21.5", + "@esbuild/win32-ia32": "0.21.5", + "@esbuild/win32-x64": "0.21.5" + } + }, "node_modules/escalade": { "version": "3.2.0", "dev": true, @@ -14084,6 +14821,12 @@ "dev": true, "license": "ISC" }, + "node_modules/html-entities": { + "version": "2.3.3", + "resolved": "https://registry.npmjs.org/html-entities/-/html-entities-2.3.3.tgz", + "integrity": "sha512-DV5Ln36z34NNTDgnz0EWGBLZENelNAtkiFA4kyNOG2tDI6Mz1uSWiq1wAKdyjnJwyDiDO7Fa2SO1CTxPXL8VxA==", + "dev": true + }, "node_modules/html-escaper": { "version": "2.0.2", "dev": true, @@ -15265,6 +16008,18 @@ "url": "https://github.com/sponsors/ljharb" } }, + "node_modules/is-what": { + "version": "4.1.16", + "resolved": "https://registry.npmjs.org/is-what/-/is-what-4.1.16.tgz", + "integrity": "sha512-ZhMwEosbFJkA0YhFnNDgTM4ZxDRsS6HqTo7qsZM08fehyRYIYa0yHu5R6mgo1n/8MgaPBXiPimPD77baVFYg+A==", + "dev": true, + "engines": { + "node": ">=12.13" + }, + "funding": { + "url": "https://github.com/sponsors/mesqueeb" + } + }, "node_modules/is-windows": { "version": "1.0.2", "dev": true, @@ -17746,6 +18501,21 @@ "node": ">=10" } }, + "node_modules/merge-anything": { + "version": "5.1.7", + "resolved": "https://registry.npmjs.org/merge-anything/-/merge-anything-5.1.7.tgz", + "integrity": "sha512-eRtbOb1N5iyH0tkQDAoQ4Ipsp/5qSR79Dzrz8hEPxRX10RWWR/iQXdoKmBSRCThY1Fh5EhISDtpSc93fpxUniQ==", + "dev": true, + "dependencies": { + "is-what": "^4.1.8" + }, + "engines": { + "node": ">=12.13" + }, + "funding": { + "url": "https://github.com/sponsors/mesqueeb" + } + }, "node_modules/merge-stream": { "version": "2.0.0", "license": "MIT" @@ -19756,6 +20526,18 @@ "parse-path": "^7.0.0" } }, + "node_modules/parse5": { + "version": "7.2.1", + "resolved": "https://registry.npmjs.org/parse5/-/parse5-7.2.1.tgz", + "integrity": "sha512-BuBYQYlv1ckiPdQi/ohiivi9Sagc9JG+Ozs0r7b/0iK3sKmrb0b9FdWdBbOdx6hBCM/F9Ir82ofnBhtZOjCRPQ==", + "dev": true, + "dependencies": { + "entities": "^4.5.0" + }, + "funding": { + "url": "https://github.com/inikulin/parse5?sponsor=1" + } + }, "node_modules/parseurl": { "version": "1.3.3", "dev": true, @@ -23429,6 +24211,25 @@ "randombytes": "^2.1.0" } }, + "node_modules/seroval": { + "version": "1.1.1", + "resolved": "https://registry.npmjs.org/seroval/-/seroval-1.1.1.tgz", + "integrity": "sha512-rqEO6FZk8mv7Hyv4UCj3FD3b6Waqft605TLfsCe/BiaylRpyyMC0b+uA5TJKawX3KzMrdi3wsLbCaLplrQmBvQ==", + "engines": { + "node": ">=10" + } + }, + "node_modules/seroval-plugins": { + "version": "1.1.1", + "resolved": "https://registry.npmjs.org/seroval-plugins/-/seroval-plugins-1.1.1.tgz", + "integrity": "sha512-qNSy1+nUj7hsCOon7AO4wdAIo9P0jrzAMp18XhiOzA6/uO5TKtP7ScozVJ8T293oRIvi5wyCHSM4TrJo/c/GJA==", + "engines": { + "node": ">=10" + }, + "peerDependencies": { + "seroval": "^1.0" + } + }, "node_modules/serve-index": { "version": "1.9.1", "dev": true, @@ -23916,6 +24717,56 @@ "node": ">= 14" } }, + "node_modules/solid-devtools": { + "version": "0.29.3", + "resolved": "https://registry.npmjs.org/solid-devtools/-/solid-devtools-0.29.3.tgz", + "integrity": "sha512-9j3VxVbEoC54ML22gAMytR8ZS1nk9xKatsWziKSkI4c/Bcyh4sxQBGESHuXSLs9xaxpyGVTmFl3hknoxEpKzlA==", + "dev": true, + "dependencies": { + "@babel/core": "^7.23.3", + "@babel/plugin-syntax-typescript": "^7.23.3", + "@babel/types": "^7.23.3", + "@solid-devtools/debugger": "^0.23.3", + "@solid-devtools/shared": "^0.13.1" + }, + "peerDependencies": { + "solid-js": "^1.8.0", + "solid-start": "^0.3.0", + "vite": "^2.2.3 || ^3.0.0 || ^4.0.0 || ^5.0.0" + }, + "peerDependenciesMeta": { + "solid-start": { + "optional": true + }, + "vite": { + "optional": true + } + } + }, + "node_modules/solid-js": { + "version": "1.9.3", + "resolved": "https://registry.npmjs.org/solid-js/-/solid-js-1.9.3.tgz", + "integrity": "sha512-5ba3taPoZGt9GY3YlsCB24kCg0Lv/rie/HTD4kG6h4daZZz7+yK02xn8Vx8dLYBc9i6Ps5JwAbEiqjmKaLB3Ag==", + "dependencies": { + "csstype": "^3.1.0", + "seroval": "^1.1.0", + "seroval-plugins": "^1.1.0" + } + }, + "node_modules/solid-refresh": { + "version": "0.6.3", + "resolved": "https://registry.npmjs.org/solid-refresh/-/solid-refresh-0.6.3.tgz", + "integrity": "sha512-F3aPsX6hVw9ttm5LYlth8Q15x6MlI/J3Dn+o3EQyRTtTxidepSTwAYdozt01/YA+7ObcciagGEyXIopGZzQtbA==", + "dev": true, + "dependencies": { + "@babel/generator": "^7.23.6", + "@babel/helper-module-imports": "^7.22.15", + "@babel/types": "^7.23.6" + }, + "peerDependencies": { + "solid-js": "^1.3" + } + }, "node_modules/sonic-boom": { "version": "2.8.0", "resolved": "https://registry.npmjs.org/sonic-boom/-/sonic-boom-2.8.0.tgz", @@ -26013,6 +26864,12 @@ "dev": true, "license": "MIT" }, + "node_modules/validate-html-nesting": { + "version": "1.2.2", + "resolved": "https://registry.npmjs.org/validate-html-nesting/-/validate-html-nesting-1.2.2.tgz", + "integrity": "sha512-hGdgQozCsQJMyfK5urgFcWEqsSSrK63Awe0t/IMR0bZ0QMtnuaiHzThW81guu3qx9abLi99NEuiaN6P9gVYsNg==", + "dev": true + }, "node_modules/validate-npm-package-license": { "version": "3.0.4", "dev": true, @@ -26121,6 +26978,103 @@ } } }, + "node_modules/vite": { + "version": "5.4.10", + "resolved": "https://registry.npmjs.org/vite/-/vite-5.4.10.tgz", + "integrity": "sha512-1hvaPshuPUtxeQ0hsVH3Mud0ZanOLwVTneA1EgbAM5LhaZEqyPWGRQ7BtaMvUrTDeEaC8pxtj6a6jku3x4z6SQ==", + "dev": true, + "dependencies": { + "esbuild": "^0.21.3", + "postcss": "^8.4.43", + "rollup": "^4.20.0" + }, + "bin": { + "vite": "bin/vite.js" + }, + "engines": { + "node": "^18.0.0 || >=20.0.0" + }, + "funding": { + "url": "https://github.com/vitejs/vite?sponsor=1" + }, + "optionalDependencies": { + "fsevents": "~2.3.3" + }, + "peerDependencies": { + "@types/node": "^18.0.0 || >=20.0.0", + "less": "*", + "lightningcss": "^1.21.0", + "sass": "*", + "sass-embedded": "*", + "stylus": "*", + "sugarss": "*", + "terser": "^5.4.0" + }, + "peerDependenciesMeta": { + "@types/node": { + "optional": true + }, + "less": { + "optional": true + }, + "lightningcss": { + "optional": true + }, + "sass": { + "optional": true + }, + "sass-embedded": { + "optional": true + }, + "stylus": { + "optional": true + }, + "sugarss": { + "optional": true + }, + "terser": { + "optional": true + } + } + }, + "node_modules/vite-plugin-solid": { + "version": "2.10.2", + "resolved": "https://registry.npmjs.org/vite-plugin-solid/-/vite-plugin-solid-2.10.2.tgz", + "integrity": "sha512-AOEtwMe2baBSXMXdo+BUwECC8IFHcKS6WQV/1NEd+Q7vHPap5fmIhLcAzr+DUJ04/KHx/1UBU0l1/GWP+rMAPQ==", + "dev": true, + "dependencies": { + "@babel/core": "^7.23.3", + "@types/babel__core": "^7.20.4", + "babel-preset-solid": "^1.8.4", + "merge-anything": "^5.1.7", + "solid-refresh": "^0.6.3", + "vitefu": "^0.2.5" + }, + "peerDependencies": { + "@testing-library/jest-dom": "^5.16.6 || ^5.17.0 || ^6.*", + "solid-js": "^1.7.2", + "vite": "^3.0.0 || ^4.0.0 || ^5.0.0" + }, + "peerDependenciesMeta": { + "@testing-library/jest-dom": { + "optional": true + } + } + }, + "node_modules/vitefu": { + "version": "0.2.5", + "resolved": "https://registry.npmjs.org/vitefu/-/vitefu-0.2.5.tgz", + "integrity": "sha512-SgHtMLoqaeeGnd2evZ849ZbACbnwQCIwRH57t18FxcXoZop0uQu0uzlIhJBlF/eWVzuce0sHeqPcDo+evVcg8Q==", + "dev": true, + "peerDependencies": { + "vite": "^3.0.0 || ^4.0.0 || ^5.0.0" + }, + "peerDependenciesMeta": { + "vite": { + "optional": true + } + } + }, "node_modules/void-elements": { "version": "3.1.0", "license": "MIT", @@ -27511,6 +28465,28 @@ } } }, + "packages/modal-ui": { + "name": "@web3auth/modal-ui", + "version": "0.0.0", + "license": "MIT", + "dependencies": { + "solid-js": "^1.8.11" + }, + "devDependencies": { + "@mertasan/tailwindcss-variables": "^2.7.0", + "autoprefixer": "^10.4.17", + "postcss": "^8.4.33", + "solid-devtools": "^0.29.2", + "tailwindcss": "^3.4.1", + "typescript": "^5.3.3", + "vite": "^5.0.11", + "vite-plugin-solid": "^2.8.2" + }, + "engines": { + "node": ">=18.x", + "npm": ">=9.x" + } + }, "packages/no-modal": { "name": "@web3auth/no-modal", "version": "9.3.1", diff --git a/package.json b/package.json index 781d0c779..d784ad88c 100644 --- a/package.json +++ b/package.json @@ -79,6 +79,7 @@ "packages/composables/*", "packages/hooks/*", "packages/modal", + "packages/modal-ui", "packages/no-modal", "packages/plugins/*", "packages/providers/*", diff --git a/packages/modal-ui/.eslintrc.json b/packages/modal-ui/.eslintrc.json new file mode 100644 index 000000000..e924287c7 --- /dev/null +++ b/packages/modal-ui/.eslintrc.json @@ -0,0 +1,32 @@ +{ + "env": { + "browser": true, + "es2020": true, + "node": true + }, + "extends": [ + "@toruslabs/eslint-config-react" + ], + "parser": "@typescript-eslint/parser", + "parserOptions": { + "ecmaVersion": 11, + "project": "./tsconfig.json", + "sourceType": "module" + }, + "root": true, + "rules": { + "@typescript-eslint/no-throw-literal": 0, + "import/extensions": [ + { + "js": "never", + "jsx": "never", + "ts": "never", + "tsx": "never" + }, + "error", + "ignorePackages" + ], + "no-console": 2, + "react/no-is-mounted": 0 + } +} diff --git a/packages/modal-ui/.gitignore b/packages/modal-ui/.gitignore new file mode 100644 index 000000000..76add878f --- /dev/null +++ b/packages/modal-ui/.gitignore @@ -0,0 +1,2 @@ +node_modules +dist \ No newline at end of file diff --git a/packages/modal-ui/README.md b/packages/modal-ui/README.md new file mode 100644 index 000000000..6a1764536 --- /dev/null +++ b/packages/modal-ui/README.md @@ -0,0 +1,34 @@ +## Usage + +Those templates dependencies are maintained via [pnpm](https://pnpm.io) via `pnpm up -Lri`. + +This is the reason you see a `pnpm-lock.yaml`. That being said, any package manager will work. This file can be safely be removed once you clone a template. + +```bash +$ npm install # or pnpm install or yarn install +``` + +### Learn more on the [Solid Website](https://solidjs.com) and come chat with us on our [Discord](https://discord.com/invite/solidjs) + +## Available Scripts + +In the project directory, you can run: + +### `npm run dev` or `npm start` + +Runs the app in the development mode.
+Open [http://localhost:3000](http://localhost:3000) to view it in the browser. + +The page will reload if you make edits.
+ +### `npm run build` + +Builds the app for production to the `dist` folder.
+It correctly bundles Solid in production mode and optimizes the build for the best performance. + +The build is minified and the filenames include the hashes.
+Your app is ready to be deployed! + +## Deployment + +You can deploy the `dist` folder to any static host provider (netlify, surge, now, etc.) diff --git a/packages/modal-ui/index.html b/packages/modal-ui/index.html new file mode 100644 index 000000000..b07fc3596 --- /dev/null +++ b/packages/modal-ui/index.html @@ -0,0 +1,15 @@ + + + + + + + Web3auth Modal UI + + + +
+ + + + diff --git a/packages/modal-ui/package.json b/packages/modal-ui/package.json new file mode 100644 index 000000000..e02e9300e --- /dev/null +++ b/packages/modal-ui/package.json @@ -0,0 +1,48 @@ +{ + "bugs": { + "url": "https://github.com/Web3Auth/Web3Auth/issues" + }, + "dependencies": { + "solid-js": "^1.8.11" + }, + "description": "Ui modal for web3Auth", + "devDependencies": { + "@babel/preset-react": "^7.25.9", + "@mertasan/tailwindcss-variables": "^2.7.0", + "autoprefixer": "^10.4.17", + "postcss": "^8.4.33", + "solid-devtools": "^0.29.2", + "tailwindcss": "^3.4.1", + "typescript": "^5.3.3", + "vite": "^5.0.11", + "vite-plugin-solid": "^2.8.2" + }, + "engines": { + "node": ">=18.x", + "npm": ">=9.x" + }, + "keywords": [ + "blockchain", + "ethereum", + "multichainWallet", + "solana", + "web3Auth", + "web3Auth/ui" + ], + "license": "MIT", + "name": "@web3auth/modal-ui", + "publishConfig": { + "access": "public" + }, + "repository": { + "type": "git", + "url": "git+https://github.com/Web3Auth/Web3Auth.git" + }, + "scripts": { + "build": "vite build", + "dev": "vite", + "serve": "vite preview", + "start": "vite" + }, + "version": "0.0.0" +} diff --git a/packages/modal-ui/postcss.config.js b/packages/modal-ui/postcss.config.js new file mode 100644 index 000000000..4be164053 --- /dev/null +++ b/packages/modal-ui/postcss.config.js @@ -0,0 +1,7 @@ +module.exports = { + purge: ['./index.html', './src/**/*.{vue,js,ts,jsx,tsx}'], + plugins: { + tailwindcss: {}, + autoprefixer: {}, + }, +}; diff --git a/packages/modal-ui/src/App.tsx b/packages/modal-ui/src/App.tsx new file mode 100644 index 000000000..4e8de8fdd --- /dev/null +++ b/packages/modal-ui/src/App.tsx @@ -0,0 +1,20 @@ +import { batch, type Component, createSignal } from "solid-js"; + +const App: Component = () => { + const [counter, setCounter] = createSignal(0); + + const incrementCounter = () => { + batch(() => { + setCounter((c) => c + 1); + }); + }; + return ( + <> +

Hello tailwind! hello

+
+ + + ); +}; + +export default App; diff --git a/packages/modal-ui/src/index.css b/packages/modal-ui/src/index.css new file mode 100644 index 000000000..b5c61c956 --- /dev/null +++ b/packages/modal-ui/src/index.css @@ -0,0 +1,3 @@ +@tailwind base; +@tailwind components; +@tailwind utilities; diff --git a/packages/modal-ui/src/index.tsx b/packages/modal-ui/src/index.tsx new file mode 100644 index 000000000..845c773c0 --- /dev/null +++ b/packages/modal-ui/src/index.tsx @@ -0,0 +1,14 @@ +/* @refresh reload */ +import "./index.css"; + +import { render } from "solid-js/web"; + +import App from "./App"; + +const root = document.getElementById("root"); + +if (import.meta.env.DEV && !(root instanceof HTMLElement)) { + throw new Error("Root element not found. Did you forget to add it to your index.html? Or maybe the id attribute got misspelled?"); +} + +render(() => , root!); diff --git a/packages/modal-ui/tailwind.config.ts b/packages/modal-ui/tailwind.config.ts new file mode 100644 index 000000000..3c3268ffd --- /dev/null +++ b/packages/modal-ui/tailwind.config.ts @@ -0,0 +1,292 @@ +/* eslint-disable import/no-extraneous-dependencies */ +import tailwindCssVariables from "@mertasan/tailwindcss-variables"; +import type { Config } from "tailwindcss"; +import colors from "tailwindcss/colors"; + +const config: Config = { + content: ["./index.html", "./src/**/*.{js,ts,jsx,tsx,css,md,mdx,html,json,scss}"], + darkMode: "class", + theme: { + extend: { + fontSize: { + xxs: "0.625rem", + }, + screens: { + smb: "380px", + xs: "440px", + mb: "570px", + tab: "840px", + }, + containers: { + smb: "380px", + xs: "440px", + mb: "570px", + tab: "840px", + sm: "640px", + md: "768px", + lg: "1024px", + xl: "1280px", + "2xl": "1536px", + }, + boxShadow: { + DEFAULT: "0px 14px 28px rgba(46, 91, 255, 0.06)", + inner: "inset 0px 4px 28px rgba(46, 91, 255, 0.06)", + dark: "0 20px 28px rgba(0,0,0,0.16)", + dark2: "5px 5px 10px #212121, -5px -5px 10px rgb(55 56 60 / 25%)", + }, + borderRadius: { + "4xl": "2rem", + }, + backgroundImage: { + "gradient-conic": "conic-gradient(transparent, var(--tw-gradient-to))", + }, + transitionDuration: { + "300": "300ms", // already exists in default config + "400": "400ms", + "500": "500ms", + }, + transitionTimingFunction: { + "in-out-quint": "cubic-bezier(0.83, 0, 0.17, 1)", + }, + translate: { + full: "100%", + "-full": "-100%", + }, + transitionProperty: { + height: "height", + spacing: "margin, padding", + }, + transformOrigin: { + top: "top", + }, + scale: { + "0": "0", + "100": "1", + }, + opacity: { + "0": "0", + "100": "1", + }, + keyframes: { + fadeIn: { + "0%": { opacity: "0" }, + "100%": { opacity: "1" }, + }, + fadeOut: { + "0%": { opacity: "1" }, + "100%": { opacity: "0" }, + }, + scaleIn: { + "0%": { transform: "scale(0.75)" }, + "100%": { transform: "scale(1)" }, + }, + scaleOut: { + "0%": { transform: "scale(1)" }, + "100%": { transform: "scale(0.75)" }, + }, + spin: { + "0%": { transform: "rotate(0deg)" }, + "100%": { transform: "rotate(360deg)" }, + }, + }, + animation: { + fadeIn: "fadeIn 0.3s ease-out forwards", + fadeOut: "fadeOut 0.3s ease-out forwards", + scaleIn: "scaleIn 0.3s ease-out forwards", + scaleOut: "scaleOut 0.3s ease-out forwards", + spin: "spin 1s linear infinite", + }, + }, + + fontFamily: { + header: ["Inter"], + body: ["Inter"], + }, + colors: { + transparent: colors.transparent, + app: { + onPrimary: "var(--app-on-primary)", + primary: { + 900: "var(--app-primary-900)", + 800: "var(--app-primary-800)", + 700: "var(--app-primary-700)", + 600: "var(--app-primary-600)", + 500: "var(--app-primary-500)", + 400: "var(--app-primary-400)", + 300: "var(--app-primary-300)", + 200: "var(--app-primary-200)", + 100: "var(--app-primary-100)", + 50: "var(--app-primary-50)", + }, + gray: { + 900: "var(--app-gray-900)", + 800: "var(--app-gray-800)", + 700: "var(--app-gray-700)", + 600: "var(--app-gray-600)", + 500: "var(--app-gray-500)", + 400: "var(--app-gray-400)", + 300: "var(--app-gray-300)", + 200: "var(--app-gray-200)", + 100: "var(--app-gray-100)", + 50: "var(--app-gray-50)", + }, + blue: { + 900: "var(--app-blue-900)", + 800: "var(--app-blue-800)", + 700: "var(--app-blue-700)", + 600: "var(--app-blue-600)", + 500: "var(--app-blue-500)", + 400: "var(--app-blue-400)", + 300: "var(--app-blue-300)", + 200: "var(--app-blue-200)", + 100: "var(--app-blue-100)", + 50: "var(--app-blue-50)", + }, + red: { + 900: "var(--app-red-900)", + 800: "var(--app-red-800)", + 700: "var(--app-red-700)", + 600: "var(--app-red-600)", + 500: "var(--app-red-500)", + 400: "var(--app-red-400)", + 300: "var(--app-red-300)", + 200: "var(--app-red-200)", + 100: "var(--app-red-100)", + 50: "var(--app-red-50)", + }, + green: { + 900: "var(--app-green-900)", + 800: "var(--app-green-800)", + 700: "var(--app-green-700)", + 600: "var(--app-green-600)", + 500: "var(--app-green-500)", + 400: "var(--app-green-400)", + 300: "var(--app-green-300)", + 200: "var(--app-green-200)", + 100: "var(--app-green-100)", + 50: "var(--app-green-50)", + }, + yellow: { + 900: "var(--app-yellow-900)", + 800: "var(--app-yellow-800)", + 700: "var(--app-yellow-700)", + 600: "var(--app-yellow-600)", + 500: "var(--app-yellow-500)", + 400: "var(--app-yellow-400)", + 300: "var(--app-yellow-300)", + 200: "var(--app-yellow-200)", + 100: "var(--app-yellow-100)", + 50: "var(--app-yellow-50)", + }, + light: { + "surface-main": "var(--app-gray-100)", + surface1: "var(--app-white)", + surface2: "var(--app-gray-50)", + surface3: "var(--app-gray-100)", + surface4: "var(--app-gray-200)", + }, + dark: { + "surface-main": "var(--app-gray-900)", + surface1: "var(--app-black)", + surface2: "var(--app-gray-900)", + surface3: "var(--app-gray-800)", + surface4: "var(--app-gray-700)", + }, + success: "var(--app-success)", + warning: "var(--app-warning)", + error: "var(--app-error)", + info: "var(--app-info)", + white: "var(--app-white)", + black: "var(--app-black)", + }, + }, + variables: { + DEFAULT: { + app: { + "on-primary": "#ffffff", + primary: { + 900: "#233876", + 800: "#1e429f", + 700: "#1a56db", + 600: "#0346ff", + 500: "#3f83f8", + 400: "#76a9fa", + 300: "#a4cafe", + 200: "#c3ddfd", + 100: "#e1effe", + 50: "#ebf5ff", + }, + gray: { + 900: "#111928", + 800: "#1f2a37", + 700: "#374151", + 600: "#4b5563", + 500: "#6b7280", + 400: "#9ca3af", + 300: "#d1d5db", + 200: "#e5e7eb", + 100: "#f3f4f6", + 50: "#f9fafb", + }, + blue: { + 900: "#233876", + 800: "#1e429f", + 700: "#1a56db", + 600: "#0346ff", + 500: "#3f83f8", + 400: "#76a9fa", + 300: "#a4cafe", + 200: "#c3ddfd", + 100: "#e1effe", + 50: "#ebf5ff", + }, + red: { + 900: "#771d1d", + 800: "#9b1c1c", + 700: "#c81e1e", + 600: "#e02424", + 500: "#f05252", + 400: "#f98080", + 300: "#f8b4b4", + 200: "#fbd5d5", + 100: "#fde8e8", + 50: "#fdf2f2", + }, + green: { + 900: "#014737", + 800: "#03543f", + 700: "#046c4e", + 600: "#057a55", + 500: "#0e9f6e", + 400: "#31c48d", + 300: "#84e1bc", + 200: "#bcf0da", + 100: "#def7ec", + 50: "#f3faf7", + }, + yellow: { + 900: "#633112", + 800: "#723b13", + 700: "#8e4b10", + 600: "#9f580a", + 500: "#c27803", + 400: "#e3a008", + 300: "#faca15", + 200: "#fce96a", + 100: "#fdf6b2", + 50: "#fdfdea", + }, + success: "#30cca4", + warning: "#fbc94a", + error: "#fb4a61", + info: "#d4d4d4", + white: "#ffffff", + black: "#000000", + }, + }, + }, + }, + plugins: [tailwindCssVariables], +}; + +export default config; diff --git a/packages/modal-ui/tsconfig.json b/packages/modal-ui/tsconfig.json new file mode 100644 index 000000000..a16fbe90c --- /dev/null +++ b/packages/modal-ui/tsconfig.json @@ -0,0 +1,23 @@ +{ + "compilerOptions": { + "allowSyntheticDefaultImports": true, + "esModuleInterop": true, + "isolatedModules": true, + "jsx": "preserve", + "jsxImportSource": "solid-js", + "module": "ESNext", + "moduleResolution": "node", + "noEmit": true, + "target": "ESNext", + "types": [ + "vite/client" + ] + }, + "extends": "../../tsconfig.json", + "include": [ + "assets", + "css", + "src", + "test" + ] +} diff --git a/packages/modal-ui/vite.config.ts b/packages/modal-ui/vite.config.ts new file mode 100644 index 000000000..74fce7ed2 --- /dev/null +++ b/packages/modal-ui/vite.config.ts @@ -0,0 +1,20 @@ +import { defineConfig } from 'vite'; +import solidPlugin from 'vite-plugin-solid'; +// import devtools from 'solid-devtools/vite'; + +export default defineConfig({ + plugins: [ + /* + Uncomment the following line to enable solid-devtools. + For more info see https://github.com/thetarnav/solid-devtools/tree/main/packages/extension#readme + */ + // devtools(), + solidPlugin(), + ], + server: { + port: 3000, + }, + build: { + target: 'esnext', + }, +}); diff --git a/packages/modal-ui/webpack.config.js b/packages/modal-ui/webpack.config.js new file mode 100644 index 000000000..7c76b9edd --- /dev/null +++ b/packages/modal-ui/webpack.config.js @@ -0,0 +1,73 @@ +/* eslint-disable @typescript-eslint/no-var-requires */ +const path = require("path"); +const generateWebpackConfig = require("../../webpack.config"); + +const pkg = require("./package.json"); + +const currentPath = path.resolve("."); + +const ssrModule = { + rules: [ + { + test: /\.css$/, + use: [ + "@toruslabs/isomorphic-style-loader", + { + loader: "css-loader", + }, + { + loader: "postcss-loader", + options: { + postcssOptions: { + plugins: { + tailwindcss: {}, + autoprefixer: {}, + }, + }, + }, + }, + ], + }, + { + test: /\.svg$/, + exclude: /node_modules/, + use: ["@svgr/webpack", "url-loader"], + }, + ], +}; + +const config = generateWebpackConfig({ + currentPath, + pkg, + alias: {}, + module: { + rules: [ + { + test: /\.css$/i, + use: [ + { loader: "style-loader", options: {} }, + { loader: "css-loader", options: {} }, + { + loader: "postcss-loader", + options: { + postcssOptions: { + plugins: { + tailwindcss: {}, + autoprefixer: {}, + }, + }, + }, + }, + ], + }, + { + test: /\.svg$/, + exclude: /node_modules/, + use: ["@svgr/webpack", "url-loader"], + }, + ], + }, + ssrModule, +}); + +module.exports = config; From 8ab49d59c3cdbf1af97fa914530bd3e52b7e6737 Mon Sep 17 00:00:00 2001 From: smgv Date: Wed, 6 Nov 2024 09:42:00 +0530 Subject: [PATCH 2/3] UI added --- .vscode/settings.json | 2 +- package-lock.json | 22 ++++++ package.json | 5 +- packages/modal-ui/package.json | 1 + packages/modal-ui/src/App.tsx | 24 +++--- .../modal-ui/src/components/Body/Body.tsx | 25 ++++++ .../src/components/Body/ConnectWallet.tsx | 78 +++++++++++++++++++ .../modal-ui/src/components/Body/Login.tsx | 38 +++++++++ .../modal-ui/src/components/Body/index.ts | 1 + .../modal-ui/src/components/Footer/Footer.tsx | 21 +++++ .../modal-ui/src/components/Footer/index.ts | 0 .../modal-ui/src/components/Modal/Modal.tsx | 78 +++++++++++++++++++ .../modal-ui/src/components/Modal/index.ts | 1 + .../SocialLoginButton/SocialLoginButton.tsx | 15 ++++ .../src/components/SocialLoginButton/index.ts | 1 + .../SocialLoginList/SocialLoginList.tsx | 45 +++++++++++ .../src/components/SocialLoginList/index.ts | 1 + .../components/WalletButton/WalletButton.tsx | 19 +++++ .../src/components/WalletButton/index.ts | 1 + packages/modal-ui/src/utils/common.tsx | 24 ++++++ packages/modal-ui/tailwind.config.ts | 69 ---------------- 21 files changed, 387 insertions(+), 84 deletions(-) create mode 100644 packages/modal-ui/src/components/Body/Body.tsx create mode 100644 packages/modal-ui/src/components/Body/ConnectWallet.tsx create mode 100644 packages/modal-ui/src/components/Body/Login.tsx create mode 100644 packages/modal-ui/src/components/Body/index.ts create mode 100644 packages/modal-ui/src/components/Footer/Footer.tsx create mode 100644 packages/modal-ui/src/components/Footer/index.ts create mode 100644 packages/modal-ui/src/components/Modal/Modal.tsx create mode 100644 packages/modal-ui/src/components/Modal/index.ts create mode 100644 packages/modal-ui/src/components/SocialLoginButton/SocialLoginButton.tsx create mode 100644 packages/modal-ui/src/components/SocialLoginButton/index.ts create mode 100644 packages/modal-ui/src/components/SocialLoginList/SocialLoginList.tsx create mode 100644 packages/modal-ui/src/components/SocialLoginList/index.ts create mode 100644 packages/modal-ui/src/components/WalletButton/WalletButton.tsx create mode 100644 packages/modal-ui/src/components/WalletButton/index.ts create mode 100644 packages/modal-ui/src/utils/common.tsx diff --git a/.vscode/settings.json b/.vscode/settings.json index 863270840..d699fc73b 100644 --- a/.vscode/settings.json +++ b/.vscode/settings.json @@ -13,5 +13,5 @@ "changeProcessCWD": true } ], - "cSpell.words": ["JRPC","Solana"] + "cSpell.words": ["clsx", "JRPC", "Ronin", "Solana"] } diff --git a/package-lock.json b/package-lock.json index ecddb4021..563b36b9e 100644 --- a/package-lock.json +++ b/package-lock.json @@ -19,6 +19,9 @@ "packages/providers/*", "packages/ui" ], + "dependencies": { + "tailwind-merge": "^2.5.4" + }, "devDependencies": { "@babel/register": "^7.25.9", "@toruslabs/config": "^2.2.0", @@ -25450,6 +25453,15 @@ "url": "https://github.com/sponsors/sindresorhus" } }, + "node_modules/tailwind-merge": { + "version": "2.5.4", + "resolved": "https://registry.npmjs.org/tailwind-merge/-/tailwind-merge-2.5.4.tgz", + "integrity": "sha512-0q8cfZHMu9nuYP/b5Shb7Y7Sh1B7Nnl5GqNr1U+n2p6+mybvRtayrQ+0042Z5byvTA8ihjlP8Odo8/VnHbZu4Q==", + "funding": { + "type": "github", + "url": "https://github.com/sponsors/dcastil" + } + }, "node_modules/tailwindcss": { "version": "3.4.14", "resolved": "https://registry.npmjs.org/tailwindcss/-/tailwindcss-3.4.14.tgz", @@ -28470,9 +28482,11 @@ "version": "0.0.0", "license": "MIT", "dependencies": { + "clsx": "^2.1.1", "solid-js": "^1.8.11" }, "devDependencies": { + "@babel/preset-react": "^7.25.9", "@mertasan/tailwindcss-variables": "^2.7.0", "autoprefixer": "^10.4.17", "postcss": "^8.4.33", @@ -28487,6 +28501,14 @@ "npm": ">=9.x" } }, + "packages/modal-ui/node_modules/clsx": { + "version": "2.1.1", + "resolved": "https://registry.npmjs.org/clsx/-/clsx-2.1.1.tgz", + "integrity": "sha512-eYm0QWBtUrBWZWG0d386OGAw16Z995PiOVo2B7bjWSbHedGl5e0ZWaq65kOGgUSNesEIDkB9ISbTg/JK9dhCZA==", + "engines": { + "node": ">=6" + } + }, "packages/no-modal": { "name": "@web3auth/no-modal", "version": "9.3.1", diff --git a/package.json b/package.json index d784ad88c..67ac92afb 100644 --- a/package.json +++ b/package.json @@ -84,5 +84,8 @@ "packages/plugins/*", "packages/providers/*", "packages/ui" - ] + ], + "dependencies": { + "tailwind-merge": "^2.5.4" + } } diff --git a/packages/modal-ui/package.json b/packages/modal-ui/package.json index e02e9300e..fc8c2b194 100644 --- a/packages/modal-ui/package.json +++ b/packages/modal-ui/package.json @@ -3,6 +3,7 @@ "url": "https://github.com/Web3Auth/Web3Auth/issues" }, "dependencies": { + "clsx": "^2.1.1", "solid-js": "^1.8.11" }, "description": "Ui modal for web3Auth", diff --git a/packages/modal-ui/src/App.tsx b/packages/modal-ui/src/App.tsx index 4e8de8fdd..288e7ff73 100644 --- a/packages/modal-ui/src/App.tsx +++ b/packages/modal-ui/src/App.tsx @@ -1,19 +1,17 @@ -import { batch, type Component, createSignal } from "solid-js"; +import { createSignal, type Component } from "solid-js"; +import { Modal } from "./components/Modal"; +import { Body } from "./components/Body"; const App: Component = () => { - const [counter, setCounter] = createSignal(0); - - const incrementCounter = () => { - batch(() => { - setCounter((c) => c + 1); - }); - }; + const [open, setOpen] = createSignal(false); return ( - <> -

Hello tailwind! hello

-
- - +
+

Try out your new modal

+ + setOpen(false)} placement="center" padding={false} showCloseIcon> + + +
); }; diff --git a/packages/modal-ui/src/components/Body/Body.tsx b/packages/modal-ui/src/components/Body/Body.tsx new file mode 100644 index 000000000..9c8c5d4dd --- /dev/null +++ b/packages/modal-ui/src/components/Body/Body.tsx @@ -0,0 +1,25 @@ +import { createSignal } from "solid-js"; +import Footer from "../Footer/Footer"; +import ConnectWallet from "./ConnectWallet"; +import Login from "./Login"; + +const PAGES = { + LOGIN: 'login', + CONNECT_WALLET: 'connect_wallet' +} + +const Body = () => { + + const [currentPage, setCurrentPage] = createSignal(PAGES.LOGIN); + + + return ( +
+ {currentPage() === PAGES.LOGIN && setCurrentPage(PAGES.CONNECT_WALLET)} />} + {currentPage() === PAGES.CONNECT_WALLET && setCurrentPage(PAGES.LOGIN)} />} +
+
+ ); +}; + +export default Body \ No newline at end of file diff --git a/packages/modal-ui/src/components/Body/ConnectWallet.tsx b/packages/modal-ui/src/components/Body/ConnectWallet.tsx new file mode 100644 index 000000000..ec4729e01 --- /dev/null +++ b/packages/modal-ui/src/components/Body/ConnectWallet.tsx @@ -0,0 +1,78 @@ +import { createSignal, For } from "solid-js" +import { WalletButton } from "../WalletButton" + +export interface ConnectWalletProps { + onBackClick?: () => void +}; + +const WALLET_LIST = ['Metamask', 'Ronin Wallet', 'Phantom', 'Rainbow', 'Trust Wallet', 'Coinbase Wallet', 'Uniswap', 'Metamask', 'Ronin Wallet', 'Phantom', 'Rainbow', 'Trust Wallet', 'Coinbase Wallet', 'Uniswap', 'Metamask', 'Ronin Wallet', 'Phantom', 'Rainbow', 'Trust Wallet', 'Coinbase Wallet', 'Uniswap'] + + +const PAGES = { + CONNECT_WALLET: 'Connect Wallet', + SELECTED_WALLET: "Selected Wallet" +} + +const ConnectWallet = ({ onBackClick }: ConnectWalletProps) => { + + const [currentPage, setCurrentPage] = createSignal(PAGES.CONNECT_WALLET); + const [selectedWallet, setSelectedWallet] = createSignal(false); + + const handleBack = () => { + if (!selectedWallet() && currentPage() === PAGES.CONNECT_WALLET && onBackClick) { + onBackClick() + } + + if (selectedWallet) { + setCurrentPage(PAGES.CONNECT_WALLET) + setSelectedWallet(false) + } + } + + return ( +
+
+
+

{currentPage()}

+
+
+ + {!selectedWallet() ?
+ +
    + + {(wallet) => + { setSelectedWallet(true); setCurrentPage(PAGES.SELECTED_WALLET) }} /> + } + +
+
: +
+
+

Scan with a WalletConnect-supported wallet or click the QR code to copy to your clipboard.

+
+

Don't have Trust Wallet?

+ +
+
+ } + + {/*
+
+
+

Install Chrome

+
+
+
+

Install Chrome

+
+
+
+

Install Chrome

+
+
*/} +
+ ) +} + +export default ConnectWallet \ No newline at end of file diff --git a/packages/modal-ui/src/components/Body/Login.tsx b/packages/modal-ui/src/components/Body/Login.tsx new file mode 100644 index 000000000..301bb5f53 --- /dev/null +++ b/packages/modal-ui/src/components/Body/Login.tsx @@ -0,0 +1,38 @@ +import SocialLoginList from "../SocialLoginList"; + +export interface LoginProps { + onExternalWalletClick?: () => void; +}; + +const Login = ({ onExternalWalletClick }: LoginProps) => { + + const handleConnectWallet = (e: MouseEvent) => { + e.preventDefault(); + if (onExternalWalletClick) onExternalWalletClick() + } + return ( +
+
+

Sign in

+

Your Web3Auth wallet with one click

+
+ + + + +
+
+ + +
+ +
+ + +
+
+
+ ) +} + +export default Login; \ No newline at end of file diff --git a/packages/modal-ui/src/components/Body/index.ts b/packages/modal-ui/src/components/Body/index.ts new file mode 100644 index 000000000..15b1fb2bb --- /dev/null +++ b/packages/modal-ui/src/components/Body/index.ts @@ -0,0 +1 @@ +export { default as Body } from "./Body"; diff --git a/packages/modal-ui/src/components/Footer/Footer.tsx b/packages/modal-ui/src/components/Footer/Footer.tsx new file mode 100644 index 000000000..ee857109b --- /dev/null +++ b/packages/modal-ui/src/components/Footer/Footer.tsx @@ -0,0 +1,21 @@ +const Footer = () => { + return ( +
+
{"modal.footer.message-new"}
+ Web3Auth Logo Light + +
+ ) +} + +export default Footer \ No newline at end of file diff --git a/packages/modal-ui/src/components/Footer/index.ts b/packages/modal-ui/src/components/Footer/index.ts new file mode 100644 index 000000000..e69de29bb diff --git a/packages/modal-ui/src/components/Modal/Modal.tsx b/packages/modal-ui/src/components/Modal/Modal.tsx new file mode 100644 index 000000000..3a1c9c70b --- /dev/null +++ b/packages/modal-ui/src/components/Modal/Modal.tsx @@ -0,0 +1,78 @@ +import { Component, JSX, createSignal, createEffect, mergeProps } from "solid-js"; +import { cn } from "../../utils/common"; + +export interface ModalProps { + children: JSX.Element[] | JSX.Element; + open: boolean; + onClose?: () => void; + placement?: 'center' | 'top-center' | 'bottom-center' | 'left' | 'right'; + padding?: boolean; + shadow?: boolean; + border?: boolean; + showCloseIcon?: boolean; +} + +const Modal: Component = (props: ModalProps) => { + + const mergedProps = mergeProps({ open: false, padding: true, placement: 'center', shadow: true, border: true, showCloseIcon: false }, props as ModalProps); + + const [isOpen, setIsOpen] = createSignal(false); + + createEffect(() => { + if (mergedProps.open) { + document.body.style.overflow = "hidden"; + // Give a very small delay for the animation to start from the correct position + setTimeout(() => { + setIsOpen(true); + }, 50); + } else { + setIsOpen(false); + // Remove overflow styling to enable scroll again. + document.body.style.overflow = ""; + } + }, false); + + + const onCloseHandler = () => { + if (mergedProps.onClose) mergedProps.onClose() + }; + + const positions: Record = { + 'center': 'top-0 left-0 items-center justify-center', + 'top-center': 'top-8 left-0 items-start justify-center', + 'bottom-center': 'bottom-8 left-0 items-end justify-center', + 'left': 'sm:left-8 flex items-center justify-center sm:justify-start', + 'right': 'sm:right-8 flex items-center justify-center sm:justify-end', + }; + + const placementClass = positions[mergedProps.placement as string] + + return ( +
+
+ {mergedProps.showCloseIcon &&
+ + + +
} + {mergedProps.children} +
+
+ + ); +}; + +export default Modal; diff --git a/packages/modal-ui/src/components/Modal/index.ts b/packages/modal-ui/src/components/Modal/index.ts new file mode 100644 index 000000000..38a0f4495 --- /dev/null +++ b/packages/modal-ui/src/components/Modal/index.ts @@ -0,0 +1 @@ +export { default as Modal } from "./Modal"; diff --git a/packages/modal-ui/src/components/SocialLoginButton/SocialLoginButton.tsx b/packages/modal-ui/src/components/SocialLoginButton/SocialLoginButton.tsx new file mode 100644 index 000000000..2c6d1d92e --- /dev/null +++ b/packages/modal-ui/src/components/SocialLoginButton/SocialLoginButton.tsx @@ -0,0 +1,15 @@ +export interface SocialLoginButtonProps { + showIcon?: boolean; + showText?: boolean; +} + +const SocialLoginButton = ({ showIcon = true, showText = true }: SocialLoginButtonProps) => { + return ( + + ); +}; + +export default SocialLoginButton; \ No newline at end of file diff --git a/packages/modal-ui/src/components/SocialLoginButton/index.ts b/packages/modal-ui/src/components/SocialLoginButton/index.ts new file mode 100644 index 000000000..ff8830f78 --- /dev/null +++ b/packages/modal-ui/src/components/SocialLoginButton/index.ts @@ -0,0 +1 @@ +export { default as SocialLoginButton } from "./SocialLoginButton"; diff --git a/packages/modal-ui/src/components/SocialLoginList/SocialLoginList.tsx b/packages/modal-ui/src/components/SocialLoginList/SocialLoginList.tsx new file mode 100644 index 000000000..f96eb6051 --- /dev/null +++ b/packages/modal-ui/src/components/SocialLoginList/SocialLoginList.tsx @@ -0,0 +1,45 @@ +import { createSignal, For } from "solid-js" +import { SocialLoginButton } from "../SocialLoginButton" +import { cn } from "../../utils/common"; + + +const SocialLoginList = () => { + + const loginMethods = () => [1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13]; + + const firstRow = loginMethods().slice(0, 3); + const otherRow = loginMethods().slice(3); + + const [expand, setExpand] = createSignal(false) + + const handleExpand = () => { + setExpand((prev) => !prev) + } + + return ( + +
+ +
+ + {(_) => + + } + +
+ {/* 224px */} +
+ + {(_) => + + } + +
+

We do not store any data related to your social logins.

+ +
+ ) +} + +export default SocialLoginList \ No newline at end of file diff --git a/packages/modal-ui/src/components/SocialLoginList/index.ts b/packages/modal-ui/src/components/SocialLoginList/index.ts new file mode 100644 index 000000000..25f8a9c2c --- /dev/null +++ b/packages/modal-ui/src/components/SocialLoginList/index.ts @@ -0,0 +1 @@ +export { default } from "./SocialLoginList"; diff --git a/packages/modal-ui/src/components/WalletButton/WalletButton.tsx b/packages/modal-ui/src/components/WalletButton/WalletButton.tsx new file mode 100644 index 000000000..b32dbad3a --- /dev/null +++ b/packages/modal-ui/src/components/WalletButton/WalletButton.tsx @@ -0,0 +1,19 @@ +export interface WalletButtonProps { + label: string; + onClick?: () => void +}; + +const WalletButton = ({ label, ...props }: WalletButtonProps) => { + return ( + + ) +} + +export default WalletButton \ No newline at end of file diff --git a/packages/modal-ui/src/components/WalletButton/index.ts b/packages/modal-ui/src/components/WalletButton/index.ts new file mode 100644 index 000000000..8d8ae3fd9 --- /dev/null +++ b/packages/modal-ui/src/components/WalletButton/index.ts @@ -0,0 +1 @@ +export { default as WalletButton } from "./WalletButton"; diff --git a/packages/modal-ui/src/utils/common.tsx b/packages/modal-ui/src/utils/common.tsx new file mode 100644 index 000000000..e4e9bc514 --- /dev/null +++ b/packages/modal-ui/src/utils/common.tsx @@ -0,0 +1,24 @@ +/** Merge classes with tailwind-merge with clsx full feature */ +import clsx, { ClassValue } from "clsx"; +import { twMerge } from "tailwind-merge"; + +const cache = new Map(); + +/** Merge classes with tailwind-merge with clsx full feature and memoization */ +export function cn(...inputs: ClassValue[]) { + // Create a cache key using JSON.stringify + const cacheKey = JSON.stringify(inputs); + + // Check if the result is already cached + if (cache.has(cacheKey)) { + return cache.get(cacheKey)!; + } + + // If not cached, compute the result + const result = twMerge(clsx(inputs)); + + // Store the result in the cache + cache.set(cacheKey, result); + + return result; +} diff --git a/packages/modal-ui/tailwind.config.ts b/packages/modal-ui/tailwind.config.ts index 3c3268ffd..f98a936cf 100644 --- a/packages/modal-ui/tailwind.config.ts +++ b/packages/modal-ui/tailwind.config.ts @@ -28,76 +28,7 @@ const config: Config = { xl: "1280px", "2xl": "1536px", }, - boxShadow: { - DEFAULT: "0px 14px 28px rgba(46, 91, 255, 0.06)", - inner: "inset 0px 4px 28px rgba(46, 91, 255, 0.06)", - dark: "0 20px 28px rgba(0,0,0,0.16)", - dark2: "5px 5px 10px #212121, -5px -5px 10px rgb(55 56 60 / 25%)", - }, - borderRadius: { - "4xl": "2rem", - }, - backgroundImage: { - "gradient-conic": "conic-gradient(transparent, var(--tw-gradient-to))", - }, - transitionDuration: { - "300": "300ms", // already exists in default config - "400": "400ms", - "500": "500ms", - }, - transitionTimingFunction: { - "in-out-quint": "cubic-bezier(0.83, 0, 0.17, 1)", - }, - translate: { - full: "100%", - "-full": "-100%", - }, - transitionProperty: { - height: "height", - spacing: "margin, padding", - }, - transformOrigin: { - top: "top", - }, - scale: { - "0": "0", - "100": "1", - }, - opacity: { - "0": "0", - "100": "1", - }, - keyframes: { - fadeIn: { - "0%": { opacity: "0" }, - "100%": { opacity: "1" }, - }, - fadeOut: { - "0%": { opacity: "1" }, - "100%": { opacity: "0" }, - }, - scaleIn: { - "0%": { transform: "scale(0.75)" }, - "100%": { transform: "scale(1)" }, - }, - scaleOut: { - "0%": { transform: "scale(1)" }, - "100%": { transform: "scale(0.75)" }, - }, - spin: { - "0%": { transform: "rotate(0deg)" }, - "100%": { transform: "rotate(360deg)" }, - }, - }, - animation: { - fadeIn: "fadeIn 0.3s ease-out forwards", - fadeOut: "fadeOut 0.3s ease-out forwards", - scaleIn: "scaleIn 0.3s ease-out forwards", - scaleOut: "scaleOut 0.3s ease-out forwards", - spin: "spin 1s linear infinite", - }, }, - fontFamily: { header: ["Inter"], body: ["Inter"], From 2887ad79a99eb198dd02d3fbb25e0be65da6cfe7 Mon Sep 17 00:00:00 2001 From: smgv Date: Mon, 11 Nov 2024 10:10:52 +0530 Subject: [PATCH 3/3] translation , config and layout changes --- demo/react-app/package-lock.json | 108 +++-- demo/vue-app-new/package-lock.json | 164 ++++---- packages/modal-ui/index.html | 4 +- packages/modal-ui/postcss.config.js | 16 +- packages/modal-ui/src/App.tsx | 4 +- .../modal-ui/src/components/Body/Body.tsx | 23 +- .../src/components/Body/ConnectWallet.tsx | 28 +- .../modal-ui/src/components/Body/Login.tsx | 24 +- .../modal-ui/src/components/Footer/Footer.tsx | 8 +- .../src/components/LoginModal/LoginModal.tsx | 87 ++++ .../src/components/LoginModal/index.ts | 1 + .../modal-ui/src/components/Modal/Modal.tsx | 30 +- .../SocialLoginButton/SocialLoginButton.tsx | 6 +- .../SocialLoginList/SocialLoginList.tsx | 12 +- .../components/WalletButton/WalletButton.tsx | 10 +- packages/modal-ui/src/config.ts | 23 ++ packages/modal-ui/src/global.d.ts | 2 + packages/modal-ui/src/i18n/dutch.json | 76 ++++ packages/modal-ui/src/i18n/english.json | 76 ++++ packages/modal-ui/src/i18n/french.json | 74 ++++ packages/modal-ui/src/i18n/german.json | 76 ++++ packages/modal-ui/src/i18n/index.ts | 12 + packages/modal-ui/src/i18n/japanese.json | 76 ++++ packages/modal-ui/src/i18n/korean.json | 76 ++++ packages/modal-ui/src/i18n/mandarin.json | 76 ++++ packages/modal-ui/src/i18n/portuguese.json | 76 ++++ packages/modal-ui/src/i18n/spanish.json | 76 ++++ packages/modal-ui/src/i18n/turkish.json | 76 ++++ packages/modal-ui/src/index.css | 12 + packages/modal-ui/src/interfaces.ts | 123 ++++++ packages/modal-ui/src/localeImport.ts | 20 + packages/modal-ui/src/loginModal.tsx | 373 ++++++++++++++++++ .../src/utils/{common.tsx => common.ts} | 0 packages/modal-ui/src/utils/modal.ts | 101 +++++ packages/modal-ui/tailwind.config.ts | 163 ++++---- 35 files changed, 1823 insertions(+), 289 deletions(-) create mode 100644 packages/modal-ui/src/components/LoginModal/LoginModal.tsx create mode 100644 packages/modal-ui/src/components/LoginModal/index.ts create mode 100644 packages/modal-ui/src/config.ts create mode 100644 packages/modal-ui/src/global.d.ts create mode 100644 packages/modal-ui/src/i18n/dutch.json create mode 100644 packages/modal-ui/src/i18n/english.json create mode 100644 packages/modal-ui/src/i18n/french.json create mode 100644 packages/modal-ui/src/i18n/german.json create mode 100644 packages/modal-ui/src/i18n/index.ts create mode 100644 packages/modal-ui/src/i18n/japanese.json create mode 100644 packages/modal-ui/src/i18n/korean.json create mode 100644 packages/modal-ui/src/i18n/mandarin.json create mode 100644 packages/modal-ui/src/i18n/portuguese.json create mode 100644 packages/modal-ui/src/i18n/spanish.json create mode 100644 packages/modal-ui/src/i18n/turkish.json create mode 100644 packages/modal-ui/src/interfaces.ts create mode 100644 packages/modal-ui/src/localeImport.ts create mode 100644 packages/modal-ui/src/loginModal.tsx rename packages/modal-ui/src/utils/{common.tsx => common.ts} (100%) create mode 100644 packages/modal-ui/src/utils/modal.ts diff --git a/demo/react-app/package-lock.json b/demo/react-app/package-lock.json index 6888e4d39..b40eb439b 100644 --- a/demo/react-app/package-lock.json +++ b/demo/react-app/package-lock.json @@ -60,15 +60,15 @@ }, "../../packages/base": { "name": "@web3auth/base", - "version": "8.12.4", + "version": "9.3.0", "license": "ISC", "dependencies": { - "@toruslabs/base-controllers": "^6.0.2", + "@toruslabs/base-controllers": "^6.2.2", "@toruslabs/constants": "^14.0.0", "@toruslabs/http-helpers": "^7.0.0", - "@web3auth/auth": "^9.1.3", + "@web3auth/auth": "^9.4.1", "jwt-decode": "^4.0.0", - "loglevel": "^1.9.1", + "loglevel": "^1.9.2", "ts-custom-error": "^3.3.1" }, "engines": { @@ -81,24 +81,24 @@ }, "../../packages/modal": { "name": "@web3auth/modal", - "version": "8.12.7", + "version": "9.3.1", "license": "ISC", "dependencies": { - "@web3auth/base": "^8.12.4", - "@web3auth/base-provider": "^8.12.4", - "@web3auth/no-modal": "^8.12.4", - "@web3auth/openlogin-adapter": "^8.12.4", - "@web3auth/ui": "^8.12.7", - "lodash.clonedeep": "^4.5.0", - "lodash.merge": "^4.6.2" + "@web3auth/auth-adapter": "^9.3.0", + "@web3auth/base": "^9.3.0", + "@web3auth/base-provider": "^9.3.0", + "@web3auth/no-modal": "^9.3.1", + "@web3auth/ui": "^9.3.1", + "deepmerge": "^4.3.1" }, "devDependencies": { "@svgr/webpack": "^8.1.0", "@toruslabs/isomorphic-style-loader": "^5.3.3", - "@toruslabs/openlogin-utils": "^8.2.1", - "@web3auth/wallet-connect-v2-adapter": "^8.12.4", + "@web3auth/account-abstraction-provider": "^9.3.1", + "@web3auth/auth": "^9.4.1", + "@web3auth/wallet-connect-v2-adapter": "^9.3.0", "css-loader": "^7.1.2", - "postcss-prefix-selector": "^1.16.1", + "postcss-prefix-selector": "^2.1.0", "style-loader": "^4.0.0", "url-loader": "^4.1.1" }, @@ -108,7 +108,7 @@ }, "peerDependencies": { "@babel/runtime": "^7.x", - "@web3auth/wallet-connect-v2-adapter": "^8.x" + "@web3auth/wallet-connect-v2-adapter": "^9.x" }, "peerDependenciesMeta": { "@web3auth/wallet-connect-v2-adapter": { @@ -118,17 +118,17 @@ }, "../../packages/plugins/wallet-services-plugin": { "name": "@web3auth/wallet-services-plugin", - "version": "8.12.5", + "version": "9.3.1", "license": "ISC", "dependencies": { - "@toruslabs/openlogin-jrpc": "^8.3.0", - "@web3auth/base": "^8.12.4", - "@web3auth/no-modal": "^8.12.4", - "@web3auth/ws-embed": "^2.0.23", - "loglevel": "^1.9.1" + "@web3auth/auth": "^9.4.1", + "@web3auth/base": "^9.3.0", + "@web3auth/no-modal": "^9.3.1", + "@web3auth/ws-embed": "^3.1.0", + "loglevel": "^1.9.2" }, "devDependencies": { - "@toruslabs/ethereum-controllers": "^6.0.2" + "@toruslabs/ethereum-controllers": "^6.2.2" }, "engines": { "node": ">=18.x", @@ -140,21 +140,18 @@ }, "../../packages/providers/account-abstraction-provider": { "name": "@web3auth/account-abstraction-provider", - "version": "8.5.0-alpha.3", + "version": "9.3.1", "license": "ISC", "dependencies": { - "@ethereumjs/common": "^4.3.0", - "@ethereumjs/tx": "^5.3.0", - "@ethereumjs/util": "^9.0.3", - "@metamask/eth-sig-util": "^7.0.2", - "@metamask/rpc-errors": "^6.2.1", - "@toruslabs/base-controllers": "^5.6.0", - "@toruslabs/openlogin-jrpc": "^8.1.1", - "@web3auth/base": "^8.5.0-alpha.3", - "@web3auth/base-provider": "^8.5.0-alpha.3", - "@web3auth/ethereum-provider": "^8.5.0-alpha.3", - "permissionless": "^0.1.29", - "viem": "^2.10.11" + "@ethereumjs/util": "^9.1.0", + "@toruslabs/base-controllers": "^6.2.2", + "@web3auth/auth": "^9.4.1", + "@web3auth/base": "^9.3.0", + "@web3auth/base-provider": "^9.3.0", + "@web3auth/ethereum-provider": "^9.3.0", + "ethers": "^6.13.4", + "permissionless": "^0.2.13", + "viem": "^2.21.36" }, "engines": { "node": ">=18.x", @@ -166,28 +163,26 @@ }, "../../packages/providers/ethereum-provider": { "name": "@web3auth/ethereum-provider", - "version": "8.12.4", + "version": "9.3.0", "license": "ISC", "dependencies": { - "@ethereumjs/common": "^4.3.0", - "@ethereumjs/tx": "^5.3.0", - "@ethereumjs/util": "^9.0.3", - "@metamask/eth-sig-util": "7.0.2", - "@toruslabs/base-controllers": "^5.10.0", - "@toruslabs/http-helpers": "^6.1.1", - "@toruslabs/openlogin-jrpc": "^8.3.0", - "@web3auth/base": "^8.12.4", - "@web3auth/base-provider": "^8.12.4", + "@ethereumjs/util": "^9.1.0", + "@toruslabs/base-controllers": "^6.2.2", + "@toruslabs/eccrypto": "^5.0.4", + "@toruslabs/http-helpers": "^7.0.0", + "@web3auth/auth": "^9.4.1", + "@web3auth/base": "^9.3.0", + "@web3auth/base-provider": "^9.3.0", "assert": "^2.1.0", "bignumber.js": "^9.1.2", "bn.js": "^5.2.1", - "ethers": "^6.13.2", + "ethers": "^6.13.4", "jsonschema": "^1.4.1" }, "devDependencies": { - "@types/bn.js": "^5.1.5", + "@types/bn.js": "^5.1.6", "@types/json-rpc-random-id": "^1.0.3", - "@walletconnect/types": "^2.15.1" + "@walletconnect/types": "^2.17.1" }, "engines": { "node": ">=18.x", @@ -199,22 +194,21 @@ }, "../../packages/providers/solana-provider": { "name": "@web3auth/solana-provider", - "version": "8.12.4", + "version": "9.3.0", "license": "ISC", "dependencies": { - "@toruslabs/base-controllers": "^6.0.2", - "@toruslabs/openlogin-ed25519": "^8.1.0", + "@toruslabs/base-controllers": "^6.2.2", "@toruslabs/tweetnacl-js": "^1.0.4", - "@web3auth/base": "^8.12.4", - "@web3auth/base-provider": "^8.12.4", + "@web3auth/auth": "^9.4.1", + "@web3auth/base": "^9.3.0", + "@web3auth/base-provider": "^9.3.0", "bn.js": "^5.2.1", "bs58": "^5.0.0", "json-rpc-random-id": "^1.0.1" }, "devDependencies": { - "@solana/web3.js": "^1.95.3", - "@solflare-wallet/sdk": "^1.4.2", - "@types/bn.js": "^5.1.5", + "@solana/web3.js": "^1.95.4", + "@types/bn.js": "^5.1.6", "@types/bs58": "^4.0.4", "@types/json-rpc-random-id": "^1.0.3" }, diff --git a/demo/vue-app-new/package-lock.json b/demo/vue-app-new/package-lock.json index b068576a0..e7f341b24 100644 --- a/demo/vue-app-new/package-lock.json +++ b/demo/vue-app-new/package-lock.json @@ -56,12 +56,12 @@ }, "../../packages/adapters/auth-adapter": { "name": "@web3auth/auth-adapter", - "version": "9.2.3", + "version": "9.3.0", "license": "ISC", "dependencies": { "@web3auth/auth": "^9.4.1", - "@web3auth/base": "^9.2.3", - "@web3auth/base-provider": "^9.2.3", + "@web3auth/base": "^9.3.0", + "@web3auth/base-provider": "^9.3.0", "deepmerge": "^4.3.1" }, "engines": { @@ -74,11 +74,11 @@ }, "../../packages/adapters/base-evm-adapter": { "name": "@web3auth/base-evm-adapter", - "version": "9.2.3", + "version": "9.3.0", "license": "ISC", "dependencies": { "@toruslabs/base-controllers": "^6.2.2", - "@web3auth/base": "^9.2.3" + "@web3auth/base": "^9.3.0" }, "engines": { "node": ">=18.x", @@ -90,11 +90,11 @@ }, "../../packages/adapters/base-solana-adapter": { "name": "@web3auth/base-solana-adapter", - "version": "9.2.3", + "version": "9.3.0", "license": "ISC", "dependencies": { "@toruslabs/base-controllers": "^6.2.2", - "@web3auth/base": "^9.2.3", + "@web3auth/base": "^9.3.0", "bs58": "^5.0.0" }, "devDependencies": { @@ -110,11 +110,11 @@ }, "../../packages/adapters/coinbase-adapter": { "name": "@web3auth/coinbase-adapter", - "version": "9.2.3", + "version": "9.3.0", "license": "ISC", "dependencies": { - "@web3auth/base": "^9.2.3", - "@web3auth/base-evm-adapter": "^9.2.3" + "@web3auth/base": "^9.3.0", + "@web3auth/base-evm-adapter": "^9.3.0" }, "devDependencies": { "@coinbase/wallet-sdk": "^4.1.0" @@ -130,12 +130,12 @@ }, "../../packages/adapters/default-evm-adapter": { "name": "@web3auth/default-evm-adapter", - "version": "9.2.3", + "version": "9.3.0", "license": "ISC", "dependencies": { - "@web3auth/base": "^9.2.3", - "@web3auth/base-evm-adapter": "^9.2.3", - "@web3auth/wallet-connect-v2-adapter": "^9.2.3", + "@web3auth/base": "^9.3.0", + "@web3auth/base-evm-adapter": "^9.3.0", + "@web3auth/wallet-connect-v2-adapter": "^9.3.0", "mipd": "^0.0.7" }, "engines": { @@ -148,19 +148,19 @@ }, "../../packages/adapters/default-solana-adapter": { "name": "@web3auth/default-solana-adapter", - "version": "9.2.3", + "version": "9.3.0", "license": "ISC", "dependencies": { "@solana/wallet-standard-features": "^1.2.0", - "@solana/web3.js": "^1.95.3", + "@solana/web3.js": "^1.95.4", "@wallet-standard/app": "^1.0.1", "@wallet-standard/base": "^1.0.1", "@wallet-standard/features": "^1.0.3", "@web3auth/auth": "^9.4.1", - "@web3auth/base": "^9.2.3", - "@web3auth/base-solana-adapter": "^9.2.3", - "@web3auth/solana-provider": "^9.2.3", - "@web3auth/wallet-connect-v2-adapter": "^9.2.3", + "@web3auth/base": "^9.3.0", + "@web3auth/base-solana-adapter": "^9.3.0", + "@web3auth/solana-provider": "^9.3.0", + "@web3auth/wallet-connect-v2-adapter": "^9.3.0", "bn.js": "^5.2.1" }, "engines": { @@ -173,12 +173,12 @@ }, "../../packages/adapters/torus-evm-adapter": { "name": "@web3auth/torus-evm-adapter", - "version": "9.2.3", + "version": "9.3.0", "license": "ISC", "dependencies": { "@toruslabs/torus-embed": "^5.0.0", - "@web3auth/base": "^9.2.3", - "@web3auth/base-evm-adapter": "^9.2.3" + "@web3auth/base": "^9.3.0", + "@web3auth/base-evm-adapter": "^9.3.0" }, "engines": { "node": ">=18.x", @@ -190,14 +190,14 @@ }, "../../packages/adapters/torus-solana-adapter": { "name": "@web3auth/torus-solana-adapter", - "version": "9.2.3", + "version": "9.3.0", "license": "ISC", "dependencies": { "@toruslabs/solana-embed": "^2.1.0", - "@web3auth/base": "^9.2.3", - "@web3auth/base-provider": "^9.2.3", - "@web3auth/base-solana-adapter": "^9.2.3", - "@web3auth/solana-provider": "^9.2.3" + "@web3auth/base": "^9.3.0", + "@web3auth/base-provider": "^9.3.0", + "@web3auth/base-solana-adapter": "^9.3.0", + "@web3auth/solana-provider": "^9.3.0" }, "engines": { "node": ">=18.x", @@ -210,19 +210,19 @@ }, "../../packages/adapters/wallet-connect-v2-adapter": { "name": "@web3auth/wallet-connect-v2-adapter", - "version": "9.2.3", + "version": "9.3.0", "license": "ISC", "dependencies": { - "@solana/web3.js": "^1.95.3", + "@solana/web3.js": "^1.95.4", "@toruslabs/base-controllers": "^6.2.2", - "@walletconnect/sign-client": "^2.17.0", - "@walletconnect/types": "^2.17.0", - "@walletconnect/utils": "^2.17.0", + "@walletconnect/sign-client": "^2.17.1", + "@walletconnect/types": "^2.17.1", + "@walletconnect/utils": "^2.17.1", "@web3auth/auth": "^9.4.1", - "@web3auth/base": "^9.2.3", - "@web3auth/base-provider": "^9.2.3", - "@web3auth/ethereum-provider": "^9.2.3", - "@web3auth/solana-provider": "^9.2.3", + "@web3auth/base": "^9.3.0", + "@web3auth/base-provider": "^9.3.0", + "@web3auth/ethereum-provider": "^9.3.0", + "@web3auth/solana-provider": "^9.3.0", "bs58": "^5.0.0", "deepmerge": "^4.3.1" }, @@ -239,7 +239,7 @@ }, "../../packages/base": { "name": "@web3auth/base", - "version": "9.2.3", + "version": "9.3.0", "license": "ISC", "dependencies": { "@toruslabs/base-controllers": "^6.2.2", @@ -260,15 +260,15 @@ }, "../../packages/composables/modal-vue-composables": { "name": "@web3auth/modal-vue-composables", - "version": "9.2.3", + "version": "9.3.1", "license": "ISC", "dependencies": { - "@web3auth/base": "^9.2.3", - "@web3auth/modal": "^9.2.3" + "@web3auth/base": "^9.3.0", + "@web3auth/modal": "^9.3.1" }, "devDependencies": { "@web3auth/auth": "^9.4.1", - "@web3auth/auth-adapter": "^9.2.3" + "@web3auth/auth-adapter": "^9.3.0" }, "engines": { "node": ">=18.x", @@ -281,24 +281,24 @@ }, "../../packages/modal": { "name": "@web3auth/modal", - "version": "9.2.3", + "version": "9.3.1", "license": "ISC", "dependencies": { - "@web3auth/auth-adapter": "^9.2.3", - "@web3auth/base": "^9.2.3", - "@web3auth/base-provider": "^9.2.3", - "@web3auth/no-modal": "^9.2.3", - "@web3auth/ui": "^9.2.3", + "@web3auth/auth-adapter": "^9.3.0", + "@web3auth/base": "^9.3.0", + "@web3auth/base-provider": "^9.3.0", + "@web3auth/no-modal": "^9.3.1", + "@web3auth/ui": "^9.3.1", "deepmerge": "^4.3.1" }, "devDependencies": { "@svgr/webpack": "^8.1.0", "@toruslabs/isomorphic-style-loader": "^5.3.3", - "@web3auth/account-abstraction-provider": "^9.2.3", + "@web3auth/account-abstraction-provider": "^9.3.1", "@web3auth/auth": "^9.4.1", - "@web3auth/wallet-connect-v2-adapter": "^9.2.3", + "@web3auth/wallet-connect-v2-adapter": "^9.3.0", "css-loader": "^7.1.2", - "postcss-prefix-selector": "^1.16.1", + "postcss-prefix-selector": "^2.1.0", "style-loader": "^4.0.0", "url-loader": "^4.1.1" }, @@ -318,18 +318,18 @@ }, "../../packages/no-modal": { "name": "@web3auth/no-modal", - "version": "9.2.3", + "version": "9.3.1", "license": "ISC", "dependencies": { "@web3auth/auth": "^9.4.1", - "@web3auth/base": "^9.2.3", - "@web3auth/base-provider": "^9.2.3", + "@web3auth/base": "^9.3.0", + "@web3auth/base-provider": "^9.3.0", "deepmerge": "^4.3.1" }, "devDependencies": { - "@web3auth/account-abstraction-provider": "^9.2.3", - "@web3auth/auth-adapter": "^9.2.3", - "@web3auth/wallet-connect-v2-adapter": "^9.2.3" + "@web3auth/account-abstraction-provider": "^9.3.1", + "@web3auth/auth-adapter": "^9.3.0", + "@web3auth/wallet-connect-v2-adapter": "^9.3.0" }, "engines": { "node": ">=18.x", @@ -351,13 +351,13 @@ }, "../../packages/plugins/solana-wallet-connector-plugin": { "name": "@web3auth/solana-wallet-connector-plugin", - "version": "9.2.3", + "version": "9.3.1", "license": "ISC", "dependencies": { "@toruslabs/solana-embed": "^2.1.0", "@web3auth/auth": "^9.4.1", - "@web3auth/base": "^9.2.3", - "@web3auth/no-modal": "^9.2.3", + "@web3auth/base": "^9.3.0", + "@web3auth/no-modal": "^9.3.1", "loglevel": "^1.9.2" }, "engines": { @@ -370,13 +370,13 @@ }, "../../packages/plugins/wallet-services-plugin": { "name": "@web3auth/wallet-services-plugin", - "version": "9.2.3", + "version": "9.3.1", "license": "ISC", "dependencies": { "@web3auth/auth": "^9.4.1", - "@web3auth/base": "^9.2.3", - "@web3auth/no-modal": "^9.2.3", - "@web3auth/ws-embed": "^3.0.0", + "@web3auth/base": "^9.3.0", + "@web3auth/no-modal": "^9.3.1", + "@web3auth/ws-embed": "^3.1.0", "loglevel": "^1.9.2" }, "devDependencies": { @@ -392,18 +392,18 @@ }, "../../packages/providers/account-abstraction-provider": { "name": "@web3auth/account-abstraction-provider", - "version": "9.2.3", + "version": "9.3.1", "license": "ISC", "dependencies": { "@ethereumjs/util": "^9.1.0", "@toruslabs/base-controllers": "^6.2.2", "@web3auth/auth": "^9.4.1", - "@web3auth/base": "^9.2.3", - "@web3auth/base-provider": "^9.2.3", - "@web3auth/ethereum-provider": "^9.2.3", - "ethers": "^6.13.3", - "permissionless": "^0.2.7", - "viem": "^2.21.19" + "@web3auth/base": "^9.3.0", + "@web3auth/base-provider": "^9.3.0", + "@web3auth/ethereum-provider": "^9.3.0", + "ethers": "^6.13.4", + "permissionless": "^0.2.13", + "viem": "^2.21.36" }, "engines": { "node": ">=18.x", @@ -477,12 +477,12 @@ }, "../../packages/providers/base-provider": { "name": "@web3auth/base-provider", - "version": "9.2.3", + "version": "9.3.0", "license": "ISC", "dependencies": { "@toruslabs/base-controllers": "^6.2.2", "@web3auth/auth": "^9.4.1", - "@web3auth/base": "^9.2.3", + "@web3auth/base": "^9.3.0", "json-rpc-random-id": "^1.0.1" }, "devDependencies": { @@ -498,7 +498,7 @@ }, "../../packages/providers/ethereum-provider": { "name": "@web3auth/ethereum-provider", - "version": "9.2.3", + "version": "9.3.0", "license": "ISC", "dependencies": { "@ethereumjs/util": "^9.1.0", @@ -506,18 +506,18 @@ "@toruslabs/eccrypto": "^5.0.4", "@toruslabs/http-helpers": "^7.0.0", "@web3auth/auth": "^9.4.1", - "@web3auth/base": "^9.2.3", - "@web3auth/base-provider": "^9.2.3", + "@web3auth/base": "^9.3.0", + "@web3auth/base-provider": "^9.3.0", "assert": "^2.1.0", "bignumber.js": "^9.1.2", "bn.js": "^5.2.1", - "ethers": "^6.13.3", + "ethers": "^6.13.4", "jsonschema": "^1.4.1" }, "devDependencies": { "@types/bn.js": "^5.1.6", "@types/json-rpc-random-id": "^1.0.3", - "@walletconnect/types": "^2.17.0" + "@walletconnect/types": "^2.17.1" }, "engines": { "node": ">=18.x", @@ -529,20 +529,20 @@ }, "../../packages/providers/solana-provider": { "name": "@web3auth/solana-provider", - "version": "9.2.3", + "version": "9.3.0", "license": "ISC", "dependencies": { "@toruslabs/base-controllers": "^6.2.2", "@toruslabs/tweetnacl-js": "^1.0.4", "@web3auth/auth": "^9.4.1", - "@web3auth/base": "^9.2.3", - "@web3auth/base-provider": "^9.2.3", + "@web3auth/base": "^9.3.0", + "@web3auth/base-provider": "^9.3.0", "bn.js": "^5.2.1", "bs58": "^5.0.0", "json-rpc-random-id": "^1.0.1" }, "devDependencies": { - "@solana/web3.js": "^1.95.3", + "@solana/web3.js": "^1.95.4", "@types/bn.js": "^5.1.6", "@types/bs58": "^4.0.4", "@types/json-rpc-random-id": "^1.0.3" diff --git a/packages/modal-ui/index.html b/packages/modal-ui/index.html index b07fc3596..3386e2b40 100644 --- a/packages/modal-ui/index.html +++ b/packages/modal-ui/index.html @@ -1,4 +1,4 @@ - + @@ -8,7 +8,7 @@ -
+
diff --git a/packages/modal-ui/postcss.config.js b/packages/modal-ui/postcss.config.js index 4be164053..f5174a67c 100644 --- a/packages/modal-ui/postcss.config.js +++ b/packages/modal-ui/postcss.config.js @@ -1,7 +1,19 @@ +const prefix = ".w3a-parent-container"; + module.exports = { - purge: ['./index.html', './src/**/*.{vue,js,ts,jsx,tsx}'], + purge: ["./index.html", "./src/**/*.{vue,js,ts,jsx,tsx}"], plugins: { tailwindcss: {}, - autoprefixer: {}, + "postcss-prefix-selector": { + prefix, + transform(_, selector, prefixedSelector) { + // if selector is already the prefix just return it + // e.g. in the case of css vars that we put under prefix + if (selector === prefix) { + return selector; + } + return prefixedSelector; + }, + }, }, }; diff --git a/packages/modal-ui/src/App.tsx b/packages/modal-ui/src/App.tsx index 288e7ff73..e22270550 100644 --- a/packages/modal-ui/src/App.tsx +++ b/packages/modal-ui/src/App.tsx @@ -5,8 +5,8 @@ import { Body } from "./components/Body"; const App: Component = () => { const [open, setOpen] = createSignal(false); return ( -
-

Try out your new modal

+
+

Try out your new modal

setOpen(false)} placement="center" padding={false} showCloseIcon> diff --git a/packages/modal-ui/src/components/Body/Body.tsx b/packages/modal-ui/src/components/Body/Body.tsx index 9c8c5d4dd..5253e9784 100644 --- a/packages/modal-ui/src/components/Body/Body.tsx +++ b/packages/modal-ui/src/components/Body/Body.tsx @@ -1,20 +1,33 @@ -import { createSignal } from "solid-js"; +import { createEffect, createSignal, on } from "solid-js"; import Footer from "../Footer/Footer"; import ConnectWallet from "./ConnectWallet"; import Login from "./Login"; +import { SocialLoginEventType, ExternalWalletEventType, StateEmitterEvents, ModalState, MODAL_STATUS } from "../../interfaces"; +import { LOGIN_PROVIDER, type SafeEventEmitter } from "@web3auth/auth"; +import { ADAPTER_NAMES, ChainNamespaceType, cloneDeep, log, WalletRegistry } from "@web3auth/base"; +import deepmerge from "deepmerge"; +// import { on } from "events"; +export interface BodyProps { + stateListener: SafeEventEmitter; + appLogo?: string; + appName?: string; + chainNamespace: ChainNamespaceType; + walletRegistry?: WalletRegistry; + handleSocialLoginClick: (params: SocialLoginEventType) => void; + handleExternalWalletClick: (params: ExternalWalletEventType) => void; + handleShowExternalWallets: (externalWalletsInitialized: boolean) => void; +} const PAGES = { LOGIN: 'login', CONNECT_WALLET: 'connect_wallet' } -const Body = () => { - +const Body = (props: BodyProps) => { const [currentPage, setCurrentPage] = createSignal(PAGES.LOGIN); - return ( -
+
{currentPage() === PAGES.LOGIN && setCurrentPage(PAGES.CONNECT_WALLET)} />} {currentPage() === PAGES.CONNECT_WALLET && setCurrentPage(PAGES.LOGIN)} />}