@lumiapassport/ui-kit 1.14.6 → 1.14.7
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/iframe/index.html +1 -1
- package/dist/iframe/main.js +1 -1
- package/dist/index.cjs +8 -12
- package/dist/index.cjs.map +1 -1
- package/dist/index.js +8 -12
- package/dist/index.js.map +1 -1
- package/package.json +1 -1
package/dist/iframe/index.html
CHANGED
|
@@ -15,7 +15,7 @@
|
|
|
15
15
|
<meta http-equiv="X-Content-Type-Options" content="nosniff" />
|
|
16
16
|
<meta http-equiv="Referrer-Policy" content="strict-origin-when-cross-origin" />
|
|
17
17
|
|
|
18
|
-
<title>Lumia Passport Secure Wallet - iframe version 1.14.
|
|
18
|
+
<title>Lumia Passport Secure Wallet - iframe version 1.14.7</title>
|
|
19
19
|
|
|
20
20
|
<!-- Styles will be injected by build process -->
|
|
21
21
|
<style>
|
package/dist/iframe/main.js
CHANGED
|
@@ -4286,7 +4286,7 @@ var SigningManager = class extends TokenRefreshApiClient {
|
|
|
4286
4286
|
};
|
|
4287
4287
|
|
|
4288
4288
|
// src/iframe/main.ts
|
|
4289
|
-
var IFRAME_VERSION = "1.14.
|
|
4289
|
+
var IFRAME_VERSION = "1.14.7";
|
|
4290
4290
|
var IframeWallet = class {
|
|
4291
4291
|
constructor() {
|
|
4292
4292
|
console.log("=".repeat(60));
|
package/dist/index.cjs
CHANGED
|
@@ -4568,7 +4568,7 @@ var import_react52 = require("react");
|
|
|
4568
4568
|
// package.json
|
|
4569
4569
|
var package_default = {
|
|
4570
4570
|
name: "@lumiapassport/ui-kit",
|
|
4571
|
-
version: "1.14.
|
|
4571
|
+
version: "1.14.7",
|
|
4572
4572
|
description: "React UI components and hooks for Lumia Passport authentication and Account Abstraction",
|
|
4573
4573
|
type: "module",
|
|
4574
4574
|
main: "./dist/index.cjs",
|
|
@@ -10357,7 +10357,7 @@ function mapBlockscoutToAsset(balance) {
|
|
|
10357
10357
|
if (type === "erc721") {
|
|
10358
10358
|
formattedBalance = "1";
|
|
10359
10359
|
} else if (decimals !== void 0) {
|
|
10360
|
-
formattedBalance =
|
|
10360
|
+
formattedBalance = (0, import_viem4.formatUnits)(BigInt(value), decimals);
|
|
10361
10361
|
} else {
|
|
10362
10362
|
formattedBalance = value;
|
|
10363
10363
|
}
|
|
@@ -10516,7 +10516,8 @@ function useBlockscoutAssets(options) {
|
|
|
10516
10516
|
const registry = await publicClient2.readContract({
|
|
10517
10517
|
address: tokenAddress,
|
|
10518
10518
|
abi: ERC3643_ABI,
|
|
10519
|
-
functionName: "identityRegistry"
|
|
10519
|
+
functionName: "identityRegistry",
|
|
10520
|
+
args: []
|
|
10520
10521
|
});
|
|
10521
10522
|
if (registry && registry !== "0x0000000000000000000000000000000000000000") {
|
|
10522
10523
|
return { tokenAddress, registry };
|
|
@@ -10537,7 +10538,6 @@ function useBlockscoutAssets(options) {
|
|
|
10537
10538
|
},
|
|
10538
10539
|
enabled: !!address && enabled && detectSecurityTokens && erc20TokenAddresses.length > 0 && !!publicClient2,
|
|
10539
10540
|
staleTime: BLOCKSCOUT_QUERY_STALE_TIME * 2,
|
|
10540
|
-
// Less frequent refresh for contract calls
|
|
10541
10541
|
gcTime: BLOCKSCOUT_QUERY_GC_TIME,
|
|
10542
10542
|
retry: 1
|
|
10543
10543
|
});
|
|
@@ -10661,6 +10661,7 @@ var ASSETS_RATES_QUERY_KEY = "lumia-passport-assets-rates-query-key";
|
|
|
10661
10661
|
function PortfolioItem(props) {
|
|
10662
10662
|
const { address, asset, isProjectAsset } = props;
|
|
10663
10663
|
const [nftImageError, setNftImageError] = (0, import_react40.useState)(false);
|
|
10664
|
+
const [logoError, setLogoError] = (0, import_react40.useState)(false);
|
|
10664
10665
|
const { assets: projectAssets, showBalanceAs: showBalanceAsSymbol } = useLumiaPassportConfig().config.current.projectAssets || {};
|
|
10665
10666
|
const qc = (0, import_react_query28.useQueryClient)();
|
|
10666
10667
|
const { balanceQueryKey } = projectAssets?.find((a) => a.symbol === showBalanceAsSymbol) || {};
|
|
@@ -10695,7 +10696,7 @@ function PortfolioItem(props) {
|
|
|
10695
10696
|
"group-hover:opacity-60 transition-opacity",
|
|
10696
10697
|
// NFTs get rounded corners, tokens get circular
|
|
10697
10698
|
isNft ? "w-12 h-12 rounded-lg" : "w-10 h-10 rounded-full",
|
|
10698
|
-
!asset.logo && !nftImage && "bg-[var(--l-pass-fg)]"
|
|
10699
|
+
(!asset.logo || logoError) && !nftImage && "bg-[var(--l-pass-fg)]"
|
|
10699
10700
|
),
|
|
10700
10701
|
children: [
|
|
10701
10702
|
isNft && nftImage && !nftImageError ? /* @__PURE__ */ (0, import_jsx_runtime52.jsx)(
|
|
@@ -10709,18 +10710,13 @@ function PortfolioItem(props) {
|
|
|
10709
10710
|
) : isNft && (!nftImage || nftImageError) ? (
|
|
10710
10711
|
// NFT placeholder when no image available
|
|
10711
10712
|
/* @__PURE__ */ (0, import_jsx_runtime52.jsx)("div", { className: "w-full h-full bg-[var(--l-pass-fg)] flex items-center justify-center", children: /* @__PURE__ */ (0, import_jsx_runtime52.jsx)(import_lucide_react34.Image, { className: "w-5 h-5 text-[var(--l-pass-fg-inverted)]" }) })
|
|
10712
|
-
) : asset.logo ? /* @__PURE__ */ (0, import_jsx_runtime52.jsx)(
|
|
10713
|
+
) : asset.logo && !logoError ? /* @__PURE__ */ (0, import_jsx_runtime52.jsx)(
|
|
10713
10714
|
"img",
|
|
10714
10715
|
{
|
|
10715
10716
|
src: asset.logo,
|
|
10716
10717
|
alt: asset.symbol,
|
|
10717
10718
|
className: "w-full h-full object-cover",
|
|
10718
|
-
onError: (
|
|
10719
|
-
const target = e.target;
|
|
10720
|
-
target.style.display = "none";
|
|
10721
|
-
target.parentElement.classList.add("bg-[var(--l-pass-fg)]");
|
|
10722
|
-
target.parentElement.innerHTML = `<span class="text-[var(--l-pass-fg-inverted)] font-bold text-sm">${asset.symbol.charAt(0)}</span>`;
|
|
10723
|
-
}
|
|
10719
|
+
onError: () => setLogoError(true)
|
|
10724
10720
|
}
|
|
10725
10721
|
) : /* @__PURE__ */ (0, import_jsx_runtime52.jsx)("span", { className: "text-[var(--l-pass-fg-inverted)] font-bold text-sm", children: asset.symbol.charAt(0) }),
|
|
10726
10722
|
isNft && /* @__PURE__ */ (0, import_jsx_runtime52.jsx)("div", { className: "absolute -top-1 -right-1 w-4 h-4 rounded-full bg-[var(--l-pass-accent)] flex items-center justify-center", children: /* @__PURE__ */ (0, import_jsx_runtime52.jsx)(import_lucide_react34.Sparkles, { className: "w-2.5 h-2.5 text-[var(--l-pass-fg-inverted)]" }) }),
|