@coinlist-co/react 0.12.1-rc.b902290 → 0.12.1-rc.df659d8
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.
- package/dist/{chunk-DX4VTV7L.js → chunk-3EOK47CQ.js} +2 -2
- package/dist/{chunk-DOSABR7Q.js → chunk-I5EHOV7V.js} +2 -2
- package/dist/{chunk-2YEJXE2V.js → chunk-VSYGGTI6.js} +8 -4
- package/dist/chunk-VSYGGTI6.js.map +1 -0
- package/dist/client/index.cjs +3912 -3896
- package/dist/client/index.cjs.map +1 -1
- package/dist/client/index.d.cts +22 -28
- package/dist/client/index.d.ts +22 -28
- package/dist/client/index.js +3960 -3948
- package/dist/client/index.js.map +1 -1
- package/dist/server/index.cjs.map +1 -1
- package/dist/server/index.js +2 -2
- package/dist/universal/index.cjs +7 -3
- package/dist/universal/index.cjs.map +1 -1
- package/dist/universal/index.js +2 -2
- package/package.json +1 -1
- package/dist/chunk-2YEJXE2V.js.map +0 -1
- /package/dist/{chunk-DX4VTV7L.js.map → chunk-3EOK47CQ.js.map} +0 -0
- /package/dist/{chunk-DOSABR7Q.js.map → chunk-I5EHOV7V.js.map} +0 -0
|
@@ -19,7 +19,7 @@ import {
|
|
|
19
19
|
generateSecureRandomBase64Url,
|
|
20
20
|
internalLogger,
|
|
21
21
|
sha256
|
|
22
|
-
} from "./chunk-
|
|
22
|
+
} from "./chunk-VSYGGTI6.js";
|
|
23
23
|
|
|
24
24
|
// src/universal/types/oauth.ts
|
|
25
25
|
var AuthorizationCode = (value) => value;
|
|
@@ -354,4 +354,4 @@ export {
|
|
|
354
354
|
UserEmail,
|
|
355
355
|
User
|
|
356
356
|
};
|
|
357
|
-
//# sourceMappingURL=chunk-
|
|
357
|
+
//# sourceMappingURL=chunk-3EOK47CQ.js.map
|
|
@@ -7,7 +7,7 @@ import {
|
|
|
7
7
|
getUUIDv4,
|
|
8
8
|
internalLogger,
|
|
9
9
|
viemChain
|
|
10
|
-
} from "./chunk-
|
|
10
|
+
} from "./chunk-VSYGGTI6.js";
|
|
11
11
|
|
|
12
12
|
// src/universal/api/nabu/config.ts
|
|
13
13
|
var NABU_BASE_URL = "https://asset.coinlist.co";
|
|
@@ -402,4 +402,4 @@ export {
|
|
|
402
402
|
SDK_LOGGER_NAME,
|
|
403
403
|
loggerOverPino
|
|
404
404
|
};
|
|
405
|
-
//# sourceMappingURL=chunk-
|
|
405
|
+
//# sourceMappingURL=chunk-I5EHOV7V.js.map
|
|
@@ -1166,10 +1166,14 @@ function parseBlockchainAmount(amount, decimals) {
|
|
|
1166
1166
|
if (/[eE]/.test(trimmed)) {
|
|
1167
1167
|
return { valid: false, reason: { type: "invalid-format" } };
|
|
1168
1168
|
}
|
|
1169
|
-
if (
|
|
1169
|
+
if (trimmed === ".") {
|
|
1170
1170
|
return { valid: false, reason: { type: "invalid-format" } };
|
|
1171
1171
|
}
|
|
1172
|
-
const
|
|
1172
|
+
const normalised = trimmed.replace(/^\./, "0.").replace(/\.$/, "");
|
|
1173
|
+
if (!/^\d+(\.\d+)?$/.test(normalised)) {
|
|
1174
|
+
return { valid: false, reason: { type: "invalid-format" } };
|
|
1175
|
+
}
|
|
1176
|
+
const [, fraction = ""] = normalised.split(".");
|
|
1173
1177
|
if (fraction.length > decimals) {
|
|
1174
1178
|
return {
|
|
1175
1179
|
valid: false,
|
|
@@ -1177,7 +1181,7 @@ function parseBlockchainAmount(amount, decimals) {
|
|
|
1177
1181
|
};
|
|
1178
1182
|
}
|
|
1179
1183
|
try {
|
|
1180
|
-
const raw = parseUnits(
|
|
1184
|
+
const raw = parseUnits(normalised, decimals);
|
|
1181
1185
|
if (raw > MAX_UINT_256) {
|
|
1182
1186
|
return { valid: false, reason: { type: "overflow" } };
|
|
1183
1187
|
}
|
|
@@ -3437,4 +3441,4 @@ export {
|
|
|
3437
3441
|
OAuthRefreshToken,
|
|
3438
3442
|
OAuthSession
|
|
3439
3443
|
};
|
|
3440
|
-
//# sourceMappingURL=chunk-
|
|
3444
|
+
//# sourceMappingURL=chunk-VSYGGTI6.js.map
|