@deloraprotocol/widget 1.0.11 → 1.0.12
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 +47 -4
- package/dist/index.js +85159 -15551
- package/dist/index.js.map +1 -1
- package/dist/styles.css +1 -1
- package/package.json +1 -1
package/dist/index.d.ts
CHANGED
|
@@ -29,6 +29,8 @@ export declare interface MyWidgetVars {
|
|
|
29
29
|
success?: string;
|
|
30
30
|
danger?: string;
|
|
31
31
|
overlay?: string;
|
|
32
|
+
/** Full-page modal scrim (blur + tint). Light: #F8F8FA-based; dark: #080808-based. */
|
|
33
|
+
modalBackdrop?: string;
|
|
32
34
|
shadow?: string;
|
|
33
35
|
radius: string;
|
|
34
36
|
fontFamily: string;
|
|
@@ -110,12 +112,35 @@ export declare interface TradeWidgetActionPayload {
|
|
|
110
112
|
}
|
|
111
113
|
|
|
112
114
|
export declare interface TradeWidgetConfig {
|
|
113
|
-
/** Legacy
|
|
115
|
+
/** Legacy alias for assetBaseUrl. Used only for resolving relative image paths such as /img/... */
|
|
114
116
|
dataBaseUrl?: string;
|
|
115
|
-
/**
|
|
116
|
-
|
|
117
|
-
/**
|
|
117
|
+
/** Optional Delora API base URL, similar to LI.FI apiUrl customization. */
|
|
118
|
+
apiUrl?: string;
|
|
119
|
+
/** Optional per-chain RPC override map. If provided for a chain, it replaces public rpcUrls from Delora metadata. */
|
|
120
|
+
rpcUrls?: TradeWidgetRpcUrlsByChainId;
|
|
121
|
+
/** Optional integrator identifier passed to Delora quote requests. */
|
|
122
|
+
integrator?: string;
|
|
123
|
+
/**
|
|
124
|
+
* Optional Delora API key sent via x-api-key header.
|
|
125
|
+
* Warning: using this in a browser widget exposes the key to clients.
|
|
126
|
+
*/
|
|
127
|
+
apiKey?: string;
|
|
128
|
+
/** Optional fee passed to Delora quote requests. */
|
|
129
|
+
fee?: number | string;
|
|
130
|
+
/** Optional initial slippage override for quote requests and the settings UI. */
|
|
131
|
+
slippage?: number;
|
|
132
|
+
/** Optional list of bridges to exclude in Delora /v1/quotes requests. */
|
|
133
|
+
excludeBridges?: string[];
|
|
134
|
+
/** Optional list of exchanges to exclude in Delora /v1/quotes requests. */
|
|
135
|
+
excludeExchanges?: string[];
|
|
136
|
+
/** Base URL for resolving relative image paths (e.g. /img/...). Defaults to dataBaseUrl, apiUrl, or the Delora API base. */
|
|
118
137
|
assetBaseUrl?: string;
|
|
138
|
+
/** Optional Terms of Use URL used in the wallet-connect consent footer. */
|
|
139
|
+
termsUrl?: string;
|
|
140
|
+
/** Optional Privacy Policy URL used in the wallet-connect consent footer. */
|
|
141
|
+
privacyPolicyUrl?: string;
|
|
142
|
+
/** WalletConnect Cloud project id (EVM QR flow). Defaults to the same id as the main Angular app. */
|
|
143
|
+
walletConnectProjectId?: string;
|
|
119
144
|
/** @deprecated Wallet state is now owned by the widget. */
|
|
120
145
|
isWalletConnected?: boolean;
|
|
121
146
|
/** @deprecated Wallet connect flow is now owned by the widget. */
|
|
@@ -175,6 +200,8 @@ export declare interface TradeWidgetQuotePayload {
|
|
|
175
200
|
quote: QuoteResponse;
|
|
176
201
|
}
|
|
177
202
|
|
|
203
|
+
export declare type TradeWidgetRpcUrlsByChainId = Partial<Record<number, string[]>>;
|
|
204
|
+
|
|
178
205
|
export declare interface TradeWidgetSideFilters {
|
|
179
206
|
includeNetworkIds?: number[];
|
|
180
207
|
excludeNetworkIds?: number[];
|
|
@@ -201,9 +228,25 @@ declare global {
|
|
|
201
228
|
interface Window {
|
|
202
229
|
ethereum?: Eip1193Provider;
|
|
203
230
|
solana?: SolanaInjectedProvider;
|
|
231
|
+
solflare?: SolanaInjectedProvider;
|
|
204
232
|
phantom?: {
|
|
205
233
|
solana?: SolanaInjectedProvider;
|
|
234
|
+
ethereum?: Eip1193Provider;
|
|
235
|
+
};
|
|
236
|
+
backpack?: SolanaInjectedProvider | {
|
|
237
|
+
solana?: SolanaInjectedProvider;
|
|
238
|
+
};
|
|
239
|
+
magicEden?: {
|
|
240
|
+
solana?: SolanaInjectedProvider;
|
|
241
|
+
};
|
|
242
|
+
trustwallet?: {
|
|
243
|
+
solana?: SolanaInjectedProvider;
|
|
244
|
+
};
|
|
245
|
+
okexchain?: Eip1193Provider & {
|
|
246
|
+
solana?: SolanaInjectedProvider;
|
|
206
247
|
};
|
|
248
|
+
coinbaseWalletExtension?: Eip1193Provider;
|
|
249
|
+
coinbaseSolana?: SolanaInjectedProvider;
|
|
207
250
|
}
|
|
208
251
|
}
|
|
209
252
|
|