feat: transaction framework

This commit is contained in:
aaa
2025-02-03 17:23:16 +08:00
parent 0425cd90a6
commit 8ce7f902af
10 changed files with 252 additions and 30 deletions

17
utils/currency.ts Normal file
View File

@@ -0,0 +1,17 @@
// 定义支持的货币类型
type Currency = "USD" | "EUR" | "GBP" | "JPY" | "CNY";
// 定义货币类型到 HTML 字符的映射
const currencySymbols: Record<Currency, string> = {
USD: "&#36;", // 美元符号
EUR: "&#8364;", // 欧元符号
GBP: "&#163;", // 英镑符号
JPY: "&#165;", // 日元符号
CNY: "&#165;", // 人民币符号(与日元相同)
};
export function CurrencyTypeToSymbol(currencyType: string){
return currencySymbols[currencyType] || "";
}