-
Notifications
You must be signed in to change notification settings - Fork 560
[SDK] Handle different fiat currencies in payment widgets #7578
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Changes from all commits
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
--- | ||
"thirdweb": patch | ||
--- | ||
|
||
Handle different fiat currencies in payment widgets |
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -7,5 +7,5 @@ export type Token = { | |
symbol: string; | ||
name: string; | ||
iconUri?: string; | ||
priceUsd: number; | ||
prices: Record<string, number>; | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. 💡 Verification agent 🧩 Analysis chainBreaking change: Token price structure updated. The change from Verify that all consumers of the 🏁 Script executed: #!/bin/bash
# Description: Find any remaining references to priceUsd that might need updating
# Expected: Minimal or no results, indicating successful migration
echo "Searching for remaining priceUsd references..."
rg "priceUsd" --type ts --type tsx -A 2 -B 2
echo "Searching for direct property access patterns..."
rg "\.priceUsd" --type ts --type tsx -A 2 -B 2 Length of output: 359 🏁 Script executed: #!/bin/bash
# Retry searching for any remaining references to priceUsd across TS and TSX files
echo "Searching for occurrences of priceUsd in .ts and .tsx files..."
rg "\bpriceUsd\b" -g "*.ts" -g "*.tsx" -n -C2
echo
echo "Searching for direct property access patterns (.priceUsd)..."
rg "\.priceUsd" -g "*.ts" -g "*.tsx" -n -C2 Length of output: 18312 Fix required: migrate all remaining We’ve identified numerous leftover • Story fixtures
Ensure each 🤖 Prompt for AI Agents
|
||
}; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
🛠️ Refactor suggestion
Export CURRENCIES array to enable reuse.
The currency list is comprehensive and well-structured. However, it should be exported to prevent duplication in other files like
LeftSection.tsx
.This will allow other components to import and use the same currency list, maintaining consistency across the codebase.
📝 Committable suggestion
🤖 Prompt for AI Agents