@lumiapassport/ui-kit 1.14.4 → 1.14.6
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 +1383 -989
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.cts +56 -1
- package/dist/index.d.ts +56 -1
- package/dist/index.js +1198 -802
- package/dist/index.js.map +1 -1
- package/dist/styles.css +1 -1
- package/package.json +2 -2
package/dist/index.d.cts
CHANGED
|
@@ -21,16 +21,71 @@ interface TokenBalance {
|
|
|
21
21
|
formattedBalance: string;
|
|
22
22
|
logo?: string;
|
|
23
23
|
}
|
|
24
|
+
/**
|
|
25
|
+
* Asset type classification
|
|
26
|
+
*/
|
|
27
|
+
type AssetType = 'native' | 'erc20' | 'erc721' | 'erc1155' | 'erc3643';
|
|
28
|
+
/**
|
|
29
|
+
* NFT metadata from token instance
|
|
30
|
+
*/
|
|
31
|
+
interface NFTMetadata {
|
|
32
|
+
/** NFT name from metadata */
|
|
33
|
+
name?: string;
|
|
34
|
+
/** NFT description */
|
|
35
|
+
description?: string;
|
|
36
|
+
/** Image URL (resolved from IPFS if needed) */
|
|
37
|
+
image?: string;
|
|
38
|
+
/** External URL for more info */
|
|
39
|
+
externalUrl?: string;
|
|
40
|
+
/** Collection name */
|
|
41
|
+
collectionName?: string;
|
|
42
|
+
/** Additional attributes */
|
|
43
|
+
attributes?: Array<{
|
|
44
|
+
trait_type: string;
|
|
45
|
+
value: string | number;
|
|
46
|
+
}>;
|
|
47
|
+
}
|
|
48
|
+
/**
|
|
49
|
+
* Compliance status for security tokens (ERC3643)
|
|
50
|
+
*/
|
|
51
|
+
interface ComplianceStatus {
|
|
52
|
+
/** Whether the token is a security token (ERC3643) */
|
|
53
|
+
isSecurityToken: boolean;
|
|
54
|
+
/** Identity registry address */
|
|
55
|
+
identityRegistry?: `0x${string}`;
|
|
56
|
+
/** Whether current user is verified */
|
|
57
|
+
isVerified?: boolean;
|
|
58
|
+
/** Transfer restrictions message */
|
|
59
|
+
transferRestrictions?: string;
|
|
60
|
+
}
|
|
61
|
+
/**
|
|
62
|
+
* Represents a token or NFT asset
|
|
63
|
+
*/
|
|
24
64
|
interface Asset {
|
|
25
|
-
|
|
65
|
+
/** Asset type classification */
|
|
66
|
+
type: AssetType;
|
|
67
|
+
/** Contract address (undefined for native token) */
|
|
26
68
|
address?: `0x${string}`;
|
|
69
|
+
/** Human-readable token name */
|
|
27
70
|
name: string;
|
|
71
|
+
/** Token symbol (e.g., "LUMIA", "USDC") */
|
|
28
72
|
symbol: string;
|
|
73
|
+
/** Raw balance as string (wei for fungible, count for NFT) */
|
|
29
74
|
balance: string;
|
|
75
|
+
/** Human-readable formatted balance */
|
|
30
76
|
formattedBalance: string;
|
|
77
|
+
/** Decimal precision (undefined for NFTs) */
|
|
31
78
|
decimals?: number;
|
|
79
|
+
/** NFT token ID (only for ERC721/ERC1155) */
|
|
32
80
|
tokenId?: string;
|
|
81
|
+
/** Token logo URL */
|
|
33
82
|
logo?: string;
|
|
83
|
+
/** NFT image URL (only for ERC721/ERC1155) */
|
|
84
|
+
image?: string;
|
|
85
|
+
/** NFT metadata (only for ERC721/ERC1155) */
|
|
86
|
+
nftMetadata?: NFTMetadata;
|
|
87
|
+
/** Security token compliance status (only for ERC3643) */
|
|
88
|
+
complianceStatus?: ComplianceStatus;
|
|
34
89
|
}
|
|
35
90
|
declare function useAssets(address?: `0x${string}`): {
|
|
36
91
|
nativeBalance: {
|
package/dist/index.d.ts
CHANGED
|
@@ -21,16 +21,71 @@ interface TokenBalance {
|
|
|
21
21
|
formattedBalance: string;
|
|
22
22
|
logo?: string;
|
|
23
23
|
}
|
|
24
|
+
/**
|
|
25
|
+
* Asset type classification
|
|
26
|
+
*/
|
|
27
|
+
type AssetType = 'native' | 'erc20' | 'erc721' | 'erc1155' | 'erc3643';
|
|
28
|
+
/**
|
|
29
|
+
* NFT metadata from token instance
|
|
30
|
+
*/
|
|
31
|
+
interface NFTMetadata {
|
|
32
|
+
/** NFT name from metadata */
|
|
33
|
+
name?: string;
|
|
34
|
+
/** NFT description */
|
|
35
|
+
description?: string;
|
|
36
|
+
/** Image URL (resolved from IPFS if needed) */
|
|
37
|
+
image?: string;
|
|
38
|
+
/** External URL for more info */
|
|
39
|
+
externalUrl?: string;
|
|
40
|
+
/** Collection name */
|
|
41
|
+
collectionName?: string;
|
|
42
|
+
/** Additional attributes */
|
|
43
|
+
attributes?: Array<{
|
|
44
|
+
trait_type: string;
|
|
45
|
+
value: string | number;
|
|
46
|
+
}>;
|
|
47
|
+
}
|
|
48
|
+
/**
|
|
49
|
+
* Compliance status for security tokens (ERC3643)
|
|
50
|
+
*/
|
|
51
|
+
interface ComplianceStatus {
|
|
52
|
+
/** Whether the token is a security token (ERC3643) */
|
|
53
|
+
isSecurityToken: boolean;
|
|
54
|
+
/** Identity registry address */
|
|
55
|
+
identityRegistry?: `0x${string}`;
|
|
56
|
+
/** Whether current user is verified */
|
|
57
|
+
isVerified?: boolean;
|
|
58
|
+
/** Transfer restrictions message */
|
|
59
|
+
transferRestrictions?: string;
|
|
60
|
+
}
|
|
61
|
+
/**
|
|
62
|
+
* Represents a token or NFT asset
|
|
63
|
+
*/
|
|
24
64
|
interface Asset {
|
|
25
|
-
|
|
65
|
+
/** Asset type classification */
|
|
66
|
+
type: AssetType;
|
|
67
|
+
/** Contract address (undefined for native token) */
|
|
26
68
|
address?: `0x${string}`;
|
|
69
|
+
/** Human-readable token name */
|
|
27
70
|
name: string;
|
|
71
|
+
/** Token symbol (e.g., "LUMIA", "USDC") */
|
|
28
72
|
symbol: string;
|
|
73
|
+
/** Raw balance as string (wei for fungible, count for NFT) */
|
|
29
74
|
balance: string;
|
|
75
|
+
/** Human-readable formatted balance */
|
|
30
76
|
formattedBalance: string;
|
|
77
|
+
/** Decimal precision (undefined for NFTs) */
|
|
31
78
|
decimals?: number;
|
|
79
|
+
/** NFT token ID (only for ERC721/ERC1155) */
|
|
32
80
|
tokenId?: string;
|
|
81
|
+
/** Token logo URL */
|
|
33
82
|
logo?: string;
|
|
83
|
+
/** NFT image URL (only for ERC721/ERC1155) */
|
|
84
|
+
image?: string;
|
|
85
|
+
/** NFT metadata (only for ERC721/ERC1155) */
|
|
86
|
+
nftMetadata?: NFTMetadata;
|
|
87
|
+
/** Security token compliance status (only for ERC3643) */
|
|
88
|
+
complianceStatus?: ComplianceStatus;
|
|
34
89
|
}
|
|
35
90
|
declare function useAssets(address?: `0x${string}`): {
|
|
36
91
|
nativeBalance: {
|