@deloraprotocol/widget 1.0.3 → 1.0.5
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 +14 -1
- package/dist/index.js +9063 -8722
- package/dist/index.js.map +1 -1
- package/package.json +1 -1
package/dist/index.d.ts
CHANGED
|
@@ -129,15 +129,21 @@ export declare interface TradeWidgetConnectPayload {
|
|
|
129
129
|
}
|
|
130
130
|
|
|
131
131
|
export declare interface TradeWidgetErrorPayload {
|
|
132
|
-
source: "metadata" | "quote" | "selection" | "wallet" | "balances" | "execution" | "unsupported";
|
|
132
|
+
source: "metadata" | "configuration" | "quote" | "selection" | "wallet" | "balances" | "execution" | "unsupported";
|
|
133
133
|
message: string;
|
|
134
134
|
status?: number;
|
|
135
135
|
statusCode?: number;
|
|
136
136
|
error?: unknown;
|
|
137
137
|
}
|
|
138
138
|
|
|
139
|
+
export declare interface TradeWidgetFilters {
|
|
140
|
+
sell?: TradeWidgetSideFilters;
|
|
141
|
+
buy?: TradeWidgetSideFilters;
|
|
142
|
+
}
|
|
143
|
+
|
|
139
144
|
export declare interface TradeWidgetProps extends Omit<MyWidgetProps, "onError"> {
|
|
140
145
|
config: TradeWidgetConfig;
|
|
146
|
+
filters?: TradeWidgetFilters;
|
|
141
147
|
initialSellToken?: TradeWidgetTokenSelection;
|
|
142
148
|
initialBuyToken?: TradeWidgetTokenSelection;
|
|
143
149
|
initialSellNetworkId?: number;
|
|
@@ -169,6 +175,13 @@ export declare interface TradeWidgetQuotePayload {
|
|
|
169
175
|
quote: QuoteResponse;
|
|
170
176
|
}
|
|
171
177
|
|
|
178
|
+
export declare interface TradeWidgetSideFilters {
|
|
179
|
+
includeNetworkIds?: number[];
|
|
180
|
+
excludeNetworkIds?: number[];
|
|
181
|
+
includeTokens?: TradeWidgetTokenSelection[];
|
|
182
|
+
excludeTokens?: TradeWidgetTokenSelection[];
|
|
183
|
+
}
|
|
184
|
+
|
|
172
185
|
export declare type TradeWidgetStatus = "idle" | "connecting-wallet" | "loading-metadata" | "finding-quote" | "checking-allowance" | "awaiting-approve-signature" | "approve-pending" | "awaiting-swap-signature" | "swap-pending" | "success" | "error";
|
|
173
186
|
|
|
174
187
|
export declare interface TradeWidgetTokenSelection {
|