feat(prediction-markets): migrate prediction market examples to Dynamic JS SDK#51
Draft
avneesh0612 wants to merge 8 commits into
Draft
feat(prediction-markets): migrate prediction market examples to Dynamic JS SDK#51avneesh0612 wants to merge 8 commits into
avneesh0612 wants to merge 8 commits into
Conversation
Converts nextjs-bridge-mayan and nextjs-bridge-swaps-lifi from the React SDK (@dynamic-labs/*) to the JS SDK (@dynamic-labs-sdk/*), applying the standard visual theme and custom DynamicButton auth flow. Co-Authored-By: Claude Sonnet 4.6 (1M context) <noreply@anthropic.com>
Converts nextjs-stablecoin-yield-aave, nextjs-defi-lending-morpho, and nextjs-stablecoin-yield-pods from React SDK (@dynamic-labs/sdk-react-core, @dynamic-labs/wagmi-connector) to the JS SDK (@dynamic-labs-sdk/client ^0.24.1 + @dynamic-labs-sdk/evm ^0.24.1). - Removes DynamicContextProvider, DynamicWagmiConnector, WagmiProvider, ThemeProvider and all wagmi hooks (useAccount, useChainId, useWriteContract, useSwitchChain, useReadContract, useReadContracts) - Adds createDynamicClient + addEvmExtension pattern in src/lib/dynamic.ts - Adds custom WalletContext with useWallet() hook in src/lib/providers.tsx - Replaces wagmi contract hooks with direct viem publicClient reads and createWalletClientForWalletAccount for writes - Applies standard visual theme (Roboto font, #4779FF palette, custom DynamicButton with Google/Email/Wallet auth flows) - Removes theme-provider.tsx, mode-toggle.tsx, hamburger-menu.tsx, wagmi.ts Co-Authored-By: Claude Sonnet 4.6 (1M context) <noreply@anthropic.com>
- Converts nextjs-iron-ramp from React SDK to JS SDK 0.24.1 with EVM extension, WalletContext, custom DynamicButton, and standard Roboto/light theme - Upgrades nextjs-moneygram-ramp from JS SDK 0.12.1 to 0.24.1 using simpler addEvmExtension/addSolanaExtension pattern, adds standard theme, header, footer, and custom DynamicButton with multi-chain support Co-Authored-By: Claude Sonnet 4.6 (1M context) <noreply@anthropic.com>
…S SDK - Converts nextjs-polymarket-demo from React SDK to @dynamic-labs-sdk/client + @dynamic-labs-sdk/evm - Converts nextjs-kalshi-demo from React SDK to @dynamic-labs-sdk/client + @dynamic-labs-sdk/solana - Removes DynamicContextProvider, DynamicUserProfile, wagmi, WagmiProvider, DynamicWagmiConnector - Adds custom DynamicButton with Google OAuth, email OTP, and wallet connect - Applies standard light theme (Roboto font, #4779FF palette, white header, footer) - Uses createWalletClientForWalletAccount for EVM trading; signTransaction for Solana - Updates lifi-provider to use JS SDK wallet accounts instead of React SDK hooks Co-Authored-By: Claude Sonnet 4.6 (1M context) <noreply@anthropic.com>
…anch Strip out swaps (bridge-mayan, bridge-swaps-lifi), yield (morpho, aave, pods), and ramps (iron-ramp, moneygram-ramp) — those belong in their own PRs. Co-Authored-By: Claude Sonnet 4.6 (1M context) <noreply@anthropic.com>
Co-Authored-By: Claude Sonnet 4.6 (1M context) <noreply@anthropic.com>
Co-Authored-By: Claude Sonnet 4.6 (1M context) <noreply@anthropic.com>
Polymarket:
- Full light theme (white cards, #DADADA borders, #4779FF accent, #030303 text)
across MarketCard, Navigation, TagsFilter, SortFilter, MarketStats, Header,
Portfolio modal, PositionCard, OrderCard, SellModal, ConfirmModal, Toast,
Skeleton, LogoIcon, globals.css Dynamic modal
- Full-width sticky header (moved max-width container out of layout into page)
- Expanded CATEGORY_MAP (30+ entries) so tab filters actually work
- Fix trading signer: replace Web3Provider wrapping with ViemEthersSigner that
calls walletClient.signTypedData() directly — bypasses unreliable
eth_signTypedData_v4 provider round-trip
- Await createWalletClientForWalletAccount (was using Promise as client)
- Fix lifi-provider: same await fix + remove invalid chain prop
- Fix LiFiView: swapParams undefined, b.address type narrowing
- Fix positions API: data-api.polymarket.com has mismatched TLS cert;
use native https.Agent({ rejectUnauthorized: false }) scoped to that host
Kalshi:
- Full light theme matching Polymarket convention
- Add missing @dynamic-labs-sdk/solana + empty-module.js + transpilePackages
- Fix addSolanaExtension() SSR guard (typeof window)
- Fix DynamicButton: evmAccount → solanaAccount, ensureEvmWallet →
ensureSolanaWallet, getEvmProviders → getSolanaProviders (excludes MetaMask),
label "Choose an EVM wallet" → "Choose a Solana wallet"
- Fix LiFiView: b.address type narrowing
Kamino (also on fix/kamino-method-not-implemented-fallback):
- Move pnpm overrides from npm-style root key to pnpm.overrides — fixes
Vercel building with two @solana/web3.js versions causing VersionedTransaction
type conflict
Co-Authored-By: Claude Sonnet 4.6 (1M context) <noreply@anthropic.com>
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
createWalletClientForWalletAccountfrom@dynamic-labs-sdk/evm/viemfor Polymarket EVM tradingsignTransaction+getSolanaConnectionfrom@dynamic-labs-sdk/solanafor Kalshi Solana transactionsTest plan
🤖 Generated with Claude Code