@riocrypto/common 1.0.807 → 1.0.808
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
|
@@ -4,8 +4,8 @@ export declare class CryptoAsset extends Asset {
|
|
|
4
4
|
rawSymbol: Crypto;
|
|
5
5
|
constructor(rawSymbol: Crypto);
|
|
6
6
|
getImageUri(): string;
|
|
7
|
-
getName(): Crypto.SOL | "Bitcoin" | "Ethereum" | "USDC (Ethereum)" | "USDC (Polygon)" | "USDC (Solana)" | "USDT (Polygon)" | "USDT (Ethereum)";
|
|
8
|
-
getSymbol(): Crypto.SOL | "USDC (Ethereum)" | "USDC (Polygon)" | "USDC (Solana)" | "USDT (Polygon)" | "USDT (Ethereum)" | "BTC" | "ETH";
|
|
9
|
-
getGasSymbol(): Crypto.SOL | "BTC" | "ETH" | "MATIC" | "SOL";
|
|
7
|
+
getName(): Crypto.USDTTron | Crypto.SOL | "Bitcoin" | "Ethereum" | "USDC (Ethereum)" | "USDC (Polygon)" | "USDC (Solana)" | "USDT (Polygon)" | "USDT (Ethereum)";
|
|
8
|
+
getSymbol(): Crypto.USDTTron | Crypto.SOL | "USDC (Ethereum)" | "USDC (Polygon)" | "USDC (Solana)" | "USDT (Polygon)" | "USDT (Ethereum)" | "BTC" | "ETH";
|
|
9
|
+
getGasSymbol(): Crypto.SOL | "BTC" | "ETH" | "MATIC" | "TRX" | "SOL";
|
|
10
10
|
getDescription(): string;
|
|
11
11
|
}
|
|
@@ -105,6 +105,9 @@ class CryptoAsset extends Asset_1.Asset {
|
|
|
105
105
|
else if (this.rawSymbol === crypto_1.Crypto.USDCPolygon) {
|
|
106
106
|
return "MATIC";
|
|
107
107
|
}
|
|
108
|
+
else if (this.rawSymbol === crypto_1.Crypto.USDTTron) {
|
|
109
|
+
return "TRX";
|
|
110
|
+
}
|
|
108
111
|
else if (this.rawSymbol === crypto_1.Crypto.USDCSolana) {
|
|
109
112
|
return "SOL";
|
|
110
113
|
}
|
|
@@ -152,6 +155,9 @@ class CryptoAsset extends Asset_1.Asset {
|
|
|
152
155
|
}
|
|
153
156
|
else if (this.rawSymbol === crypto_1.Crypto.USDTEthereum) {
|
|
154
157
|
return "USDT on the Ethereum chain.";
|
|
158
|
+
}
|
|
159
|
+
else if (this.rawSymbol === crypto_1.Crypto.USDTTron) {
|
|
160
|
+
return "USDT on the Tron chain.";
|
|
155
161
|
// } else if (this.symbol === Crypto.mUSDC) {
|
|
156
162
|
// return "USDC on the Polygon chain";
|
|
157
163
|
// } else if (this.symbol === Crypto.USDT) {
|
|
@@ -11,7 +11,12 @@ const isValidCryptoAddress = (address, crypto) => {
|
|
|
11
11
|
return bitcoinPattern.test(address);
|
|
12
12
|
case crypto_1.Crypto.SOL:
|
|
13
13
|
return solanaPattern.test(address);
|
|
14
|
-
case crypto_1.Crypto.ETH ||
|
|
14
|
+
case crypto_1.Crypto.ETH ||
|
|
15
|
+
crypto_1.Crypto.USDC ||
|
|
16
|
+
crypto_1.Crypto.USDCPolygon ||
|
|
17
|
+
crypto_1.Crypto.USDTTron ||
|
|
18
|
+
crypto_1.Crypto.USDTPolygon ||
|
|
19
|
+
crypto_1.Crypto.USDTEthereum:
|
|
15
20
|
return ethereumPattern.test(address);
|
|
16
21
|
default:
|
|
17
22
|
return false;
|
package/build/types/crypto.d.ts
CHANGED
package/build/types/crypto.js
CHANGED