@tokenflight/swap 0.2.0 → 0.3.0-rc.0
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/active-bridge-DTyKObda.js +1 -0
- package/dist/bridge-C9uFKAdS.js +1 -0
- package/dist/bridge.d.ts +597 -0
- package/dist/bridge.js +1 -0
- package/dist/iframe.d.ts +354 -0
- package/dist/iframe.js +1 -0
- package/dist/register-defaults-lIJMUU-P.js +1 -0
- package/dist/register-widget-DQAzucnZ.js +5 -0
- package/dist/swap.css +1 -1
- package/dist/tokenflight-swap.d.ts +74 -56
- package/dist/tokenflight-swap.js +2 -2
- package/dist/tokenflight-swap.umd.cjs +6 -4
- package/dist/widget.d.ts +8 -3
- package/dist/widget.js +1 -1
- package/package.json +10 -2
- package/dist/register-widget-BjfDwWgS.js +0 -3
- /package/dist/{en-US-qDDiLksN.js → en-US-ChmhdVUe.js} +0 -0
- /package/dist/{ja-JP-C_ZBjfPb.js → ja-JP-BAX9fLqV.js} +0 -0
- /package/dist/{ko-KR-BHIB7ZQf.js → ko-KR-jwhmhUqJ.js} +0 -0
- /package/dist/{zh-CN-DpZbMBLR.js → zh-CN-fKcRI4Y8.js} +0 -0
- /package/dist/{zh-TW-CtmyKF1W.js → zh-TW-gFEUAIR6.js} +0 -0
package/dist/widget.d.ts
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { HyperstreamApi } from '@tokenflight/api';
|
|
2
2
|
|
|
3
3
|
/** Amount change data */
|
|
4
4
|
declare interface AmountChangedData {
|
|
@@ -105,6 +105,8 @@ export declare interface IWalletAdapter {
|
|
|
105
105
|
off(event: WalletEventType, handler: (event: WalletEvent) => void): void;
|
|
106
106
|
}
|
|
107
107
|
|
|
108
|
+
declare type QuoteResponse = HyperstreamApi.GetQuotesResponse;
|
|
109
|
+
|
|
108
110
|
export declare interface RegisterElementsOptions {
|
|
109
111
|
walletAdapter?: IWalletAdapter;
|
|
110
112
|
callbacks?: Callbacks;
|
|
@@ -195,7 +197,7 @@ declare interface TextOverrides {
|
|
|
195
197
|
}
|
|
196
198
|
|
|
197
199
|
/** All first-party CSS custom properties exposed for theming. */
|
|
198
|
-
declare type TfCssVar = "--tf-bg" | "--tf-bg-secondary" | "--tf-bg-elevated" | "--tf-surface" | "--tf-surface-hover" | "--tf-input-bg" | "--tf-glass" | "--tf-text" | "--tf-text-secondary" | "--tf-text-tertiary" | "--tf-text-on-primary" | "--tf-border" | "--tf-border-light" | "--tf-primary" | "--tf-primary-alpha" | "--tf-primary-light" | "--tf-primary-glow" | "--tf-success" | "--tf-success-bg" | "--tf-error" | "--tf-error-bg" | "--tf-error-alpha" | "--tf-warning" | "--tf-warning-bg" | "--tf-shadow" | "--tf-shadow-lg" | "--tf-skeleton" | "--tf-radius-xs" | "--tf-radius-sm" | "--tf-radius" | "--tf-radius-lg" | "--tf-radius-xl" | "--tf-button-radius" | "--tf-widget-max-width" | "--tf-font-family" | "--tf-font-family-mono" | "--tf-font-size" | "--tf-line-height";
|
|
200
|
+
declare type TfCssVar = "--tf-bg" | "--tf-bg-secondary" | "--tf-bg-elevated" | "--tf-surface" | "--tf-surface-hover" | "--tf-input-bg" | "--tf-glass" | "--tf-text" | "--tf-text-secondary" | "--tf-text-tertiary" | "--tf-text-on-primary" | "--tf-border" | "--tf-border-light" | "--tf-primary" | "--tf-primary-alpha" | "--tf-primary-light" | "--tf-primary-glow" | "--tf-success" | "--tf-success-bg" | "--tf-error" | "--tf-error-bg" | "--tf-error-alpha" | "--tf-warning" | "--tf-warning-bg" | "--tf-shadow" | "--tf-shadow-lg" | "--tf-skeleton" | "--tf-radius-xs" | "--tf-radius-sm" | "--tf-radius" | "--tf-radius-lg" | "--tf-radius-xl" | "--tf-button-radius" | "--tf-widget-max-width" | "--tf-font-family" | "--tf-font-family-mono" | "--tf-font-size" | "--tf-line-height" | "--tf-font-sm" | "--tf-font-base" | "--tf-font-md" | "--tf-font-lg" | "--tf-font-xl" | "--tf-font-heading" | "--tf-font-amount" | "--tf-font-amount-lg" | "--tf-font-amount-sm";
|
|
199
201
|
|
|
200
202
|
/** Visual theme mode. */
|
|
201
203
|
export declare type Theme = "light" | "dark" | "auto";
|
|
@@ -204,7 +206,7 @@ export declare type Theme = "light" | "dark" | "auto";
|
|
|
204
206
|
declare interface TokenFlightConfigBase {
|
|
205
207
|
/** HyperStream API endpoint */
|
|
206
208
|
apiEndpoint?: string;
|
|
207
|
-
/** Fiat on-ramp API endpoint (default: https://fiat
|
|
209
|
+
/** Fiat on-ramp API endpoint (default: https://fiat.hyperstream.dev) */
|
|
208
210
|
fiatApiEndpoint?: string;
|
|
209
211
|
/** Visual theme */
|
|
210
212
|
theme?: Theme;
|
|
@@ -259,6 +261,8 @@ export declare interface TokenFlightWidgetAttributes {
|
|
|
259
261
|
"trade-type"?: string;
|
|
260
262
|
amount?: string;
|
|
261
263
|
recipient?: string;
|
|
264
|
+
"recipient-editable"?: BooleanAttribute;
|
|
265
|
+
"refund-to"?: string;
|
|
262
266
|
icon?: string;
|
|
263
267
|
"lock-from-token"?: BooleanAttribute;
|
|
264
268
|
"lock-to-token"?: BooleanAttribute;
|
|
@@ -267,6 +271,7 @@ export declare interface TokenFlightWidgetAttributes {
|
|
|
267
271
|
"default-pay-method"?: "crypto" | "card";
|
|
268
272
|
"from-tokens"?: string;
|
|
269
273
|
"to-tokens"?: string;
|
|
274
|
+
"rpc-overrides"?: string;
|
|
270
275
|
"title-text"?: string;
|
|
271
276
|
"title-image"?: string;
|
|
272
277
|
theme?: Theme;
|
package/dist/widget.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
import{r as e,t}from"./register-widget-
|
|
1
|
+
import{r as e,t}from"./register-widget-DQAzucnZ.js";export{e as TokenFlightWidget,t as registerWidgetElement};
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@tokenflight/swap",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "0.3.0-rc.0",
|
|
4
4
|
"description": "Embeddable Web Components for cross-chain token swaps",
|
|
5
5
|
"license": "Apache-2.0",
|
|
6
6
|
"author": "Khalani",
|
|
@@ -26,6 +26,14 @@
|
|
|
26
26
|
"types": "./dist/widget.d.ts",
|
|
27
27
|
"import": "./dist/widget.js"
|
|
28
28
|
},
|
|
29
|
+
"./iframe": {
|
|
30
|
+
"types": "./dist/iframe.d.ts",
|
|
31
|
+
"import": "./dist/iframe.js"
|
|
32
|
+
},
|
|
33
|
+
"./bridge": {
|
|
34
|
+
"types": "./dist/bridge.d.ts",
|
|
35
|
+
"import": "./dist/bridge.js"
|
|
36
|
+
},
|
|
29
37
|
"./custom-elements": {
|
|
30
38
|
"types": "./dist/custom-elements.d.ts"
|
|
31
39
|
}
|
|
@@ -42,7 +50,7 @@
|
|
|
42
50
|
"access": "public"
|
|
43
51
|
},
|
|
44
52
|
"dependencies": {
|
|
45
|
-
"@tokenflight/api": "0.
|
|
53
|
+
"@tokenflight/api": "0.3.0-rc.0"
|
|
46
54
|
},
|
|
47
55
|
"devDependencies": {
|
|
48
56
|
"@fluenti/cli": "^0.6.2",
|