@nexus-cross/connect-kit-core 1.3.3-beta.8 → 1.3.3-beta.9
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.d.ts +19 -1
- package/dist/index.js +1 -1
- package/package.json +2 -2
package/dist/index.d.ts
CHANGED
|
@@ -158,6 +158,13 @@ interface CrossConnectKitConfig {
|
|
|
158
158
|
embeddedProjectId?: string;
|
|
159
159
|
/** App metadata for WalletConnect pairing */
|
|
160
160
|
appMetadata: AppMetadata;
|
|
161
|
+
/**
|
|
162
|
+
* Legal document links surfaced in the connect modal footer
|
|
163
|
+
* ("By continuing, you agree to … Terms of Service … Privacy Policy").
|
|
164
|
+
* When a URL is omitted the corresponding text still renders (styled in
|
|
165
|
+
* the primary color) but is not clickable. Set both to make them links.
|
|
166
|
+
*/
|
|
167
|
+
legal?: LegalLinks;
|
|
161
168
|
/** Supported networks */
|
|
162
169
|
networks: readonly NetworkConfig[];
|
|
163
170
|
/** Default network (first connection lands here) */
|
|
@@ -214,6 +221,17 @@ interface AppMetadata {
|
|
|
214
221
|
url: string;
|
|
215
222
|
icons?: string[];
|
|
216
223
|
}
|
|
224
|
+
/**
|
|
225
|
+
* URLs the connect modal's Terms of Service / Privacy Policy links point
|
|
226
|
+
* to. Each is optional — omit one to render its label as non-clickable
|
|
227
|
+
* text instead of an anchor.
|
|
228
|
+
*/
|
|
229
|
+
interface LegalLinks {
|
|
230
|
+
/** URL the "Terms of Service" link points to. */
|
|
231
|
+
termsUrl?: string;
|
|
232
|
+
/** URL the "Privacy Policy" link points to. */
|
|
233
|
+
privacyUrl?: string;
|
|
234
|
+
}
|
|
217
235
|
interface NetworkConfig {
|
|
218
236
|
/** EIP-155 numeric chain ID */
|
|
219
237
|
id: number;
|
|
@@ -367,4 +385,4 @@ declare function formatBalance(value: bigint, decimals: number, displayDecimals?
|
|
|
367
385
|
*/
|
|
368
386
|
declare function formatWei(wei: bigint, displayDecimals?: number): string;
|
|
369
387
|
|
|
370
|
-
export { type Account, type AppMetadata, type BalancePort, type ChainBalance, type ColorOverrides, ConnectionStatus, type ConnectorPort, type ConnectorResult, type ConnectorType, type CrossConnectKitConfig, type ModalControlPort, type ModalView, type NetworkConfig, type OAuthPort, type OAuthProvider, type PinKeyboardMode, type PinKeyboardOption, type StoragePort, type Theme, type ThemeMode, type ThemePort, type ThemeTokens, type Unsubscribe, type WalletDescriptor, type WalletDetectionPort, type WalletId, type WalletState, formatBalance, formatWei, resolveThemeMode };
|
|
388
|
+
export { type Account, type AppMetadata, type BalancePort, type ChainBalance, type ColorOverrides, ConnectionStatus, type ConnectorPort, type ConnectorResult, type ConnectorType, type CrossConnectKitConfig, type LegalLinks, type ModalControlPort, type ModalView, type NetworkConfig, type OAuthPort, type OAuthProvider, type PinKeyboardMode, type PinKeyboardOption, type StoragePort, type Theme, type ThemeMode, type ThemePort, type ThemeTokens, type Unsubscribe, type WalletDescriptor, type WalletDetectionPort, type WalletId, type WalletState, formatBalance, formatWei, resolveThemeMode };
|
package/dist/index.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
var f={CONNECTED:"connected",DISCONNECTED:"disconnected",CONNECTING:"connecting",RECONNECTING:"reconnecting"};function u(e,t){if(t&&typeof window<"u"&&window.matchMedia)try{return window.matchMedia("(prefers-color-scheme: dark)").matches?"dark":"light"}catch{}return typeof e=="string"?e:e&&typeof e=="object"&&"mode"in e?e.mode??"dark":"dark"}function m(e,t,r=4){if(t<0||!Number.isInteger(t))throw new RangeError(`formatBalance: decimals must be a non-negative integer, got ${t}`);if(r<0||!Number.isInteger(r))throw new RangeError(`formatBalance: displayDecimals must be a non-negative integer, got ${r}`);let n=e<0n,i=n?-e:e;if(t===0){let o=i.toString();return n?`-${o}`:o}let d=10n**BigInt(t),s=i/d,g=i%d;if(r===0){let o=s.toString();return n?`-${o}`:o}let c=g.toString().padStart(t,"0").slice(0,r),a=c.length;for(;a>0&&c.charCodeAt(a-1)===48;)a--;let l=c.slice(0,a),p=l?`${s}.${l}`:s.toString();return n?`-${p}`:p}function y(e,t=4){return m(e,18,t)}import{OnRampError as S,normalizeDisallowReason as
|
|
1
|
+
var f={CONNECTED:"connected",DISCONNECTED:"disconnected",CONNECTING:"connecting",RECONNECTING:"reconnecting"};function u(e,t){if(t&&typeof window<"u"&&window.matchMedia)try{return window.matchMedia("(prefers-color-scheme: dark)").matches?"dark":"light"}catch{}return typeof e=="string"?e:e&&typeof e=="object"&&"mode"in e?e.mode??"dark":"dark"}function m(e,t,r=4){if(t<0||!Number.isInteger(t))throw new RangeError(`formatBalance: decimals must be a non-negative integer, got ${t}`);if(r<0||!Number.isInteger(r))throw new RangeError(`formatBalance: displayDecimals must be a non-negative integer, got ${r}`);let n=e<0n,i=n?-e:e;if(t===0){let o=i.toString();return n?`-${o}`:o}let d=10n**BigInt(t),s=i/d,g=i%d;if(r===0){let o=s.toString();return n?`-${o}`:o}let c=g.toString().padStart(t,"0").slice(0,r),a=c.length;for(;a>0&&c.charCodeAt(a-1)===48;)a--;let l=c.slice(0,a),p=l?`${s}.${l}`:s.toString();return n?`-${p}`:p}function y(e,t=4){return m(e,18,t)}import{OnRampError as S,normalizeDisallowReason as k}from"@nexus-cross/onramp";export{f as ConnectionStatus,S as OnRampError,m as formatBalance,y as formatWei,k as normalizeDisallowReason,u as resolveThemeMode};
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@nexus-cross/connect-kit-core",
|
|
3
|
-
"version": "1.3.3-beta.
|
|
3
|
+
"version": "1.3.3-beta.9",
|
|
4
4
|
"description": "Core domain logic for @nexus-cross/connect-kit — types, ports, utilities",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"main": "./dist/index.js",
|
|
@@ -20,7 +20,7 @@
|
|
|
20
20
|
"access": "public"
|
|
21
21
|
},
|
|
22
22
|
"dependencies": {
|
|
23
|
-
"@nexus-cross/onramp": "1.3.3-beta.
|
|
23
|
+
"@nexus-cross/onramp": "1.3.3-beta.9"
|
|
24
24
|
},
|
|
25
25
|
"devDependencies": {
|
|
26
26
|
"tsup": "^8.4.0",
|