@unifold/ui-react 0.1.16 → 0.1.17

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/index.js CHANGED
@@ -383,9 +383,9 @@ function DepositExecutionItem({
383
383
  return timestamp;
384
384
  }
385
385
  };
386
- const formatUsdAmount = (baseUnitAmount) => {
386
+ const formatUsdAmount = (sourceAmountUsd) => {
387
387
  try {
388
- const amount = Number(baseUnitAmount) / 1e6;
388
+ const amount = Number(sourceAmountUsd);
389
389
  return new Intl.NumberFormat("en-US", {
390
390
  style: "currency",
391
391
  currency: "USD",
@@ -811,9 +811,9 @@ function DepositSuccessToast({
811
811
  return timestamp;
812
812
  }
813
813
  };
814
- const formatUsdAmount = (baseUnitAmount) => {
814
+ const formatUsdAmount = (sourceAmountUsd2) => {
815
815
  try {
816
- const amount = Number(baseUnitAmount) / 1e6;
816
+ const amount = Number(sourceAmountUsd2);
817
817
  return new Intl.NumberFormat("en-US", {
818
818
  style: "currency",
819
819
  currency: "USD",
@@ -1961,7 +1961,6 @@ function useUserIp() {
1961
1961
  queryKey: ["unifold", "userIpInfo"],
1962
1962
  queryFn: async () => {
1963
1963
  const data = await (0, import_core7.getIpAddress)();
1964
- console.log("[useUserIp] IP detected:", data);
1965
1964
  return {
1966
1965
  alpha2: data.alpha2.toLowerCase(),
1967
1966
  alpha3: data.alpha3?.toLowerCase(),
package/dist/index.mjs CHANGED
@@ -311,9 +311,9 @@ function DepositExecutionItem({
311
311
  return timestamp;
312
312
  }
313
313
  };
314
- const formatUsdAmount = (baseUnitAmount) => {
314
+ const formatUsdAmount = (sourceAmountUsd) => {
315
315
  try {
316
- const amount = Number(baseUnitAmount) / 1e6;
316
+ const amount = Number(sourceAmountUsd);
317
317
  return new Intl.NumberFormat("en-US", {
318
318
  style: "currency",
319
319
  currency: "USD",
@@ -744,9 +744,9 @@ function DepositSuccessToast({
744
744
  return timestamp;
745
745
  }
746
746
  };
747
- const formatUsdAmount = (baseUnitAmount) => {
747
+ const formatUsdAmount = (sourceAmountUsd2) => {
748
748
  try {
749
- const amount = Number(baseUnitAmount) / 1e6;
749
+ const amount = Number(sourceAmountUsd2);
750
750
  return new Intl.NumberFormat("en-US", {
751
751
  style: "currency",
752
752
  currency: "USD",
@@ -1909,7 +1909,6 @@ function useUserIp() {
1909
1909
  queryKey: ["unifold", "userIpInfo"],
1910
1910
  queryFn: async () => {
1911
1911
  const data = await getIpAddress();
1912
- console.log("[useUserIp] IP detected:", data);
1913
1912
  return {
1914
1913
  alpha2: data.alpha2.toLowerCase(),
1915
1914
  alpha3: data.alpha3?.toLowerCase(),
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@unifold/ui-react",
3
- "version": "0.1.16",
3
+ "version": "0.1.17",
4
4
  "description": "Unifold UI React - Deposit and onramp components for React applications",
5
5
  "main": "./dist/index.js",
6
6
  "module": "./dist/index.mjs",
@@ -31,7 +31,7 @@
31
31
  "lucide-react": "^0.454.0",
32
32
  "qr-code-styling": "^1.6.0-rc.1",
33
33
  "tailwind-merge": "^2.0.0",
34
- "@unifold/core": "0.1.16"
34
+ "@unifold/core": "0.1.17"
35
35
  },
36
36
  "devDependencies": {
37
37
  "@types/react": "^19.0.0",