@funkit/connect 9.2.1 → 9.3.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/CHANGELOG.md +22 -0
- package/dist/__generated__/default_configs.d.ts +31 -2
- package/dist/__generated__/default_feature_gates.d.ts +1 -0
- package/dist/{chunk-P6FYL3PM.js → chunk-FHIMKOGH.js} +20 -1
- package/dist/{chunk-VLXKSNSJ.js → chunk-NKJYA7IM.js} +20 -1
- package/dist/{chunk-3U6TWV25.js → chunk-TWG76V3I.js} +16 -4
- package/dist/clients/fanatics.css +5328 -4057
- package/dist/clients/fanatics.js +3 -3
- package/dist/components/Box/Box.d.ts +44 -44
- package/dist/components/FunButton/FunButton.css.d.ts +1 -0
- package/dist/components/FunButton/FunLinkButton.d.ts +2 -2
- package/dist/components/FunCheckoutHistory/FunDirectExecutionHistoryDetail.d.ts +1 -1
- package/dist/components/FunOptionBox/FunOptionBox.css.d.ts +1 -1
- package/dist/css/sprinkles.css.d.ts +110 -46
- package/dist/domains/relay.d.ts +2 -2
- package/dist/hooks/useSwappedPreload.d.ts +2 -3
- package/dist/index.css +5364 -4081
- package/dist/index.js +549 -582
- package/dist/modals/CheckoutModal/SourceChange/sourceChange.css.d.ts +2 -0
- package/dist/modals/CheckoutModal/SwappedIframe/SwappedIframe.d.ts +2 -15
- package/dist/modals/CheckoutModal/SwappedIframe/SwappedIframeContainer.d.ts +15 -0
- package/dist/modals/CheckoutModal/SwappedIframe/index.d.ts +1 -1
- package/dist/providers/FunkitCheckoutContext/types.d.ts +5 -5
- package/dist/providers/FunkitThemeProvider.d.ts +99 -3
- package/dist/providers/SwappedProvider.d.ts +8 -8
- package/dist/themes/baseTheme.js +1 -1
- package/dist/themes/darkTheme.js +2 -2
- package/dist/themes/lightTheme.js +2 -2
- package/dist/utils/checkout.d.ts +4 -4
- package/dist/utils/swapped.d.ts +6 -3
- package/dist/wallets/walletConnectors/bifrostWallet/bifrostWallet.js +2 -2
- package/dist/wallets/walletConnectors/bitgetWallet/bitgetWallet.js +2 -2
- package/dist/wallets/walletConnectors/bybitWallet/bybitWallet.js +2 -2
- package/dist/wallets/walletConnectors/clvWallet/clvWallet.js +2 -2
- package/dist/wallets/walletConnectors/coin98Wallet/coin98Wallet.js +2 -2
- package/dist/wallets/walletConnectors/coreWallet/coreWallet.js +2 -2
- package/dist/wallets/walletConnectors/foxWallet/foxWallet.js +2 -2
- package/dist/wallets/walletConnectors/frontierWallet/frontierWallet.js +2 -2
- package/dist/wallets/walletConnectors/gateWallet/gateWallet.js +2 -2
- package/dist/wallets/walletConnectors/index.js +43 -43
- package/dist/wallets/walletConnectors/metaMaskWallet/metaMaskWallet.js +2 -2
- package/dist/wallets/walletConnectors/okxWallet/okxWallet.js +2 -2
- package/dist/wallets/walletConnectors/rainbowWallet/rainbowWallet.js +2 -2
- package/dist/wallets/walletConnectors/roninWallet/roninWallet.js +2 -2
- package/dist/wallets/walletConnectors/safepalWallet/safepalWallet.js +2 -2
- package/dist/wallets/walletConnectors/subWallet/subWallet.js +2 -2
- package/dist/wallets/walletConnectors/tokenPocketWallet/tokenPocketWallet.js +2 -2
- package/dist/wallets/walletConnectors/trustWallet/trustWallet.js +2 -2
- package/dist/wallets/walletConnectors/zerionWallet/zerionWallet.js +2 -2
- package/package.json +2 -2
- package/dist/hooks/useIframePool.d.ts +0 -38
- package/dist/modals/CheckoutModal/SwappedIframe/SwappedIframePool.d.ts +0 -14
- package/dist/wallets/walletConnectors/{chunk-NEK7T3IC.js → chunk-4C7ER452.js} +3 -3
- package/dist/wallets/walletConnectors/{chunk-UVMMPRDM.js → chunk-53VYSPXK.js} +3 -3
- package/dist/wallets/walletConnectors/{chunk-I7K6LUZR.js → chunk-6UCI7GM6.js} +3 -3
- package/dist/wallets/walletConnectors/{chunk-3Y2GG3PM.js → chunk-6YO27XOM.js} +3 -3
- package/dist/wallets/walletConnectors/{chunk-DWMUM4F6.js → chunk-7OARWILZ.js} +3 -3
- package/dist/wallets/walletConnectors/{chunk-FDVJHNLL.js → chunk-CJJT7LMT.js} +3 -3
- package/dist/wallets/walletConnectors/{chunk-CT3QPTAU.js → chunk-EKJHJFRN.js} +3 -3
- package/dist/wallets/walletConnectors/{chunk-TIT5F32X.js → chunk-GH4M6FTK.js} +3 -3
- package/dist/wallets/walletConnectors/{chunk-UVYZSGIX.js → chunk-GSHSWVEG.js} +3 -3
- package/dist/wallets/walletConnectors/{chunk-CMLFDRCP.js → chunk-GVOQTORD.js} +3 -3
- package/dist/wallets/walletConnectors/{chunk-3YCR2ZB4.js → chunk-HETS3KKI.js} +3 -3
- package/dist/wallets/walletConnectors/{chunk-C4RP2DNH.js → chunk-HOPH3TQ3.js} +3 -3
- package/dist/wallets/walletConnectors/{chunk-CBI3SGOC.js → chunk-IICWJWGZ.js} +3 -3
- package/dist/wallets/walletConnectors/{chunk-ZMRIQOR5.js → chunk-KO56HCTI.js} +3 -3
- package/dist/wallets/walletConnectors/{chunk-COX3VEDR.js → chunk-LI6QY2B5.js} +3 -3
- package/dist/wallets/walletConnectors/{chunk-RLLTYOWT.js → chunk-PKMAPNN6.js} +3 -3
- package/dist/wallets/walletConnectors/{chunk-UPUDLUBT.js → chunk-TTHM3WUR.js} +3 -3
- package/dist/wallets/walletConnectors/{chunk-N3UJMC3V.js → chunk-XBLHZICW.js} +3 -3
|
@@ -1,6 +1,8 @@
|
|
|
1
1
|
export declare const WITH_EMPTY_STATE_DATA_ATTRIBUTE = "data-with-empty-state";
|
|
2
2
|
export declare const emptyStateStyles: string;
|
|
3
3
|
export declare const sourceListBoxStyles: string;
|
|
4
|
+
export declare const sourceListGroupContainerStyles: string;
|
|
5
|
+
export declare const sourceListGroupContainerNoLabelsStyles: string;
|
|
4
6
|
export declare const sourceListCompactBoxStyles: string;
|
|
5
7
|
export declare const removeBottomPaddingFromSurroundingDialog: string;
|
|
6
8
|
export declare const paymentMethodStaticArea: string;
|
|
@@ -1,16 +1,3 @@
|
|
|
1
|
-
import type { SwappedFormOfPayment } from '@funkit/api-base';
|
|
2
1
|
import React from 'react';
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
export type SwappedIframeState = CheckoutModalCommonState & {
|
|
6
|
-
/** The selected payment option from the fops API */
|
|
7
|
-
selectedPaymentOption: SwappedFormOfPayment;
|
|
8
|
-
/** Payment method type filter to restore when returning to SOURCE_CHANGE */
|
|
9
|
-
paymentMethodTypeFilter?: PaymentMethodType;
|
|
10
|
-
};
|
|
11
|
-
export type SwappedIframeNext = {
|
|
12
|
-
success?: boolean;
|
|
13
|
-
};
|
|
14
|
-
export declare const SwappedIframeInfo: ModalStepInfo<FunCheckoutStep.SWAPPED_IFRAME>;
|
|
15
|
-
declare function SwappedIframe({ modalState, onNext, onBack, onClose, }: ModalStepComponentProps<FunCheckoutStep.SWAPPED_IFRAME>): React.JSX.Element;
|
|
16
|
-
export default SwappedIframe;
|
|
2
|
+
declare const _default: React.MemoExoticComponent<() => React.JSX.Element | null>;
|
|
3
|
+
export default _default;
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
import type { SwappedFormOfPayment } from '@funkit/api-base';
|
|
2
|
+
import React from 'react';
|
|
3
|
+
import type { PaymentMethodType } from '../../../hooks/usePaymentSources';
|
|
4
|
+
import { type CheckoutModalCommonState, FunCheckoutStep, type ModalStepComponentProps, type ModalStepInfo } from '../../../modals/CheckoutModal/stepTransition';
|
|
5
|
+
export type SwappedIframeState = CheckoutModalCommonState & {
|
|
6
|
+
/** The selected payment option from the fops API */
|
|
7
|
+
selectedPaymentOption: SwappedFormOfPayment;
|
|
8
|
+
/** Payment method type filter to restore when returning to SOURCE_CHANGE */
|
|
9
|
+
paymentMethodTypeFilter?: PaymentMethodType;
|
|
10
|
+
};
|
|
11
|
+
export type SwappedIframeNext = {
|
|
12
|
+
success?: boolean;
|
|
13
|
+
};
|
|
14
|
+
export declare const SwappedIframeInfo: ModalStepInfo<FunCheckoutStep.SWAPPED_IFRAME>;
|
|
15
|
+
export declare function SwappedIframeContainer({ modalState, onNext, onBack, onClose, }: ModalStepComponentProps<FunCheckoutStep.SWAPPED_IFRAME>): React.JSX.Element;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
export {
|
|
1
|
+
export { SwappedIframeContainer, SwappedIframeInfo, type SwappedIframeNext, type SwappedIframeState, } from './SwappedIframeContainer';
|
|
@@ -16,13 +16,13 @@ export interface DynamicTargetAssetCandidate extends TokenInfo {
|
|
|
16
16
|
badgeText?: string;
|
|
17
17
|
targetAssetMinAmount?: number;
|
|
18
18
|
/**
|
|
19
|
-
* Exchange rate of the target asset in terms of the
|
|
20
|
-
* Represents how many
|
|
19
|
+
* Exchange rate of the target asset in terms of the finalized token.
|
|
20
|
+
* Represents how many finalized tokens one unit of the target asset can be exchanged for.
|
|
21
21
|
*
|
|
22
|
-
* Example: If `targetAsset`/`
|
|
22
|
+
* Example: If `targetAsset`/`finalizedToken` is USDT/hbUSDT and the rate is 1.01,
|
|
23
23
|
* 1 USDT can be exchanged for 1.01 hbUSDT.
|
|
24
24
|
*/
|
|
25
|
-
|
|
25
|
+
finalizedTokenRate?: number;
|
|
26
26
|
dynamicRoutingId?: string;
|
|
27
27
|
}
|
|
28
28
|
export declare enum FunCheckoutStartingStep {
|
|
@@ -74,7 +74,7 @@ export interface FunkitCheckoutConfig extends Omit<ApiFunkitCheckoutConfig, 'gen
|
|
|
74
74
|
* to specify the onchain action to execute after deposit */
|
|
75
75
|
qrcodeActionType?: string;
|
|
76
76
|
/** set this if you want enable vault like deposit*/
|
|
77
|
-
|
|
77
|
+
finalizedToken?: DynamicTargetAssetCandidate;
|
|
78
78
|
/**
|
|
79
79
|
* For dynamic routing, the id of the dynamic route to use
|
|
80
80
|
*/
|
|
@@ -55,8 +55,9 @@ export declare const useActiveTheme: () => {
|
|
|
55
55
|
secondaryText: string;
|
|
56
56
|
tertiaryText: string;
|
|
57
57
|
textSelection: string;
|
|
58
|
-
|
|
58
|
+
inputLabel: string;
|
|
59
59
|
inputBackground: string;
|
|
60
|
+
inputBackgroundHover: string;
|
|
60
61
|
inputBorderBase: string;
|
|
61
62
|
inputBorderHover: string;
|
|
62
63
|
activeTabBorderColor: string;
|
|
@@ -131,12 +132,29 @@ export declare const useActiveTheme: () => {
|
|
|
131
132
|
fiatAccountGradientTo: string;
|
|
132
133
|
optionBoxBackground: string;
|
|
133
134
|
optionBoxBackgroundUninteractive: string;
|
|
135
|
+
optionBoxBorderBase: string;
|
|
134
136
|
optionBoxBorderHover: string;
|
|
137
|
+
optionBoxDefaultModeNotActiveBorderBase: string;
|
|
138
|
+
optionBoxDefaultModeNotActiveBorderHover: string;
|
|
135
139
|
openDropdownBackgroundColor: string;
|
|
136
140
|
dropdownActiveItemBackgroundBase: string;
|
|
137
141
|
dropdownActiveItemBackgroundHover: string;
|
|
138
142
|
dropdownActiveItemBackgroundDisabled: string;
|
|
143
|
+
dropdownActiveItemBorderBase: string;
|
|
144
|
+
dropdownActiveItemBorderHover: string;
|
|
139
145
|
selectedDropdownItemBackground: string;
|
|
146
|
+
alwaysVisibleLabelBackgroundHover: string;
|
|
147
|
+
selectedDropdownItemText: string;
|
|
148
|
+
dropdownLabelColor: string;
|
|
149
|
+
copyButtonBackgroundBase: string;
|
|
150
|
+
copyButtonBackgroundHover: string;
|
|
151
|
+
copyButtonBackgroundActive: string;
|
|
152
|
+
copyButtonBorderBase: string;
|
|
153
|
+
copyButtonBorderHover: string;
|
|
154
|
+
funFeatureListBackgroundBase: string;
|
|
155
|
+
funFeatureListBackgroundHover: string;
|
|
156
|
+
funFeatureListBorderColor: string;
|
|
157
|
+
funFeatureListBorderColorHover: string;
|
|
140
158
|
spinnerBackground: string;
|
|
141
159
|
spinnerIndicator: string;
|
|
142
160
|
spinnerBackgroundVerifyAccount: string;
|
|
@@ -164,6 +182,7 @@ export declare const useActiveTheme: () => {
|
|
|
164
182
|
paymentAmountSkeletonCircleSize: string;
|
|
165
183
|
paymentMethodItemIconSize: string;
|
|
166
184
|
selectAssetItemIconSize: string;
|
|
185
|
+
sourceListGap: string;
|
|
167
186
|
txBreakdownSkeletonWidth: string;
|
|
168
187
|
txSummaryLineSkeletonHeight: string;
|
|
169
188
|
txSummaryLineSkeletonWidth: string;
|
|
@@ -359,6 +378,14 @@ export declare const useActiveTheme: () => {
|
|
|
359
378
|
fontSize: string;
|
|
360
379
|
lineHeight: string;
|
|
361
380
|
};
|
|
381
|
+
quickOptionFontSize: {
|
|
382
|
+
fontSize: string;
|
|
383
|
+
lineHeight: string;
|
|
384
|
+
};
|
|
385
|
+
useConnectedFontSize: {
|
|
386
|
+
fontSize: string;
|
|
387
|
+
lineHeight: string;
|
|
388
|
+
};
|
|
362
389
|
};
|
|
363
390
|
radii: {
|
|
364
391
|
actionButton: string;
|
|
@@ -380,6 +407,7 @@ export declare const useActiveTheme: () => {
|
|
|
380
407
|
dropdownList: string;
|
|
381
408
|
modalTopbarIcon: string;
|
|
382
409
|
withdrawalInput: string;
|
|
410
|
+
useConnected: string;
|
|
383
411
|
};
|
|
384
412
|
borderWidths: {
|
|
385
413
|
activeOptionBorderWidth: string;
|
|
@@ -442,6 +470,10 @@ export declare const useActiveTheme: () => {
|
|
|
442
470
|
youPayYouReceivePaddingLeft: string;
|
|
443
471
|
youPayYouReceivePaddingRight: string;
|
|
444
472
|
youPayYouReceivePaddingY: string;
|
|
473
|
+
inputPaddingX: string;
|
|
474
|
+
inputPaddingY: string;
|
|
475
|
+
dropdownActiveItemRegularSizePaddingY: string;
|
|
476
|
+
assetListDefaultGap: string;
|
|
445
477
|
};
|
|
446
478
|
textTransforms: {
|
|
447
479
|
inputAmountQuickOptionButton: string;
|
|
@@ -497,8 +529,9 @@ export declare const useActiveTheme: () => {
|
|
|
497
529
|
secondaryText: string;
|
|
498
530
|
tertiaryText: string;
|
|
499
531
|
textSelection: string;
|
|
500
|
-
|
|
532
|
+
inputLabel: string;
|
|
501
533
|
inputBackground: string;
|
|
534
|
+
inputBackgroundHover: string;
|
|
502
535
|
inputBorderBase: string;
|
|
503
536
|
inputBorderHover: string;
|
|
504
537
|
activeTabBorderColor: string;
|
|
@@ -573,12 +606,29 @@ export declare const useActiveTheme: () => {
|
|
|
573
606
|
fiatAccountGradientTo: string;
|
|
574
607
|
optionBoxBackground: string;
|
|
575
608
|
optionBoxBackgroundUninteractive: string;
|
|
609
|
+
optionBoxBorderBase: string;
|
|
576
610
|
optionBoxBorderHover: string;
|
|
611
|
+
optionBoxDefaultModeNotActiveBorderBase: string;
|
|
612
|
+
optionBoxDefaultModeNotActiveBorderHover: string;
|
|
577
613
|
openDropdownBackgroundColor: string;
|
|
578
614
|
dropdownActiveItemBackgroundBase: string;
|
|
579
615
|
dropdownActiveItemBackgroundHover: string;
|
|
580
616
|
dropdownActiveItemBackgroundDisabled: string;
|
|
617
|
+
dropdownActiveItemBorderBase: string;
|
|
618
|
+
dropdownActiveItemBorderHover: string;
|
|
581
619
|
selectedDropdownItemBackground: string;
|
|
620
|
+
alwaysVisibleLabelBackgroundHover: string;
|
|
621
|
+
selectedDropdownItemText: string;
|
|
622
|
+
dropdownLabelColor: string;
|
|
623
|
+
copyButtonBackgroundBase: string;
|
|
624
|
+
copyButtonBackgroundHover: string;
|
|
625
|
+
copyButtonBackgroundActive: string;
|
|
626
|
+
copyButtonBorderBase: string;
|
|
627
|
+
copyButtonBorderHover: string;
|
|
628
|
+
funFeatureListBackgroundBase: string;
|
|
629
|
+
funFeatureListBackgroundHover: string;
|
|
630
|
+
funFeatureListBorderColor: string;
|
|
631
|
+
funFeatureListBorderColorHover: string;
|
|
582
632
|
spinnerBackground: string;
|
|
583
633
|
spinnerIndicator: string;
|
|
584
634
|
spinnerBackgroundVerifyAccount: string;
|
|
@@ -606,6 +656,7 @@ export declare const useActiveTheme: () => {
|
|
|
606
656
|
paymentAmountSkeletonCircleSize: string;
|
|
607
657
|
paymentMethodItemIconSize: string;
|
|
608
658
|
selectAssetItemIconSize: string;
|
|
659
|
+
sourceListGap: string;
|
|
609
660
|
txBreakdownSkeletonWidth: string;
|
|
610
661
|
txSummaryLineSkeletonHeight: string;
|
|
611
662
|
txSummaryLineSkeletonWidth: string;
|
|
@@ -801,6 +852,14 @@ export declare const useActiveTheme: () => {
|
|
|
801
852
|
fontSize: string;
|
|
802
853
|
lineHeight: string;
|
|
803
854
|
};
|
|
855
|
+
quickOptionFontSize: {
|
|
856
|
+
fontSize: string;
|
|
857
|
+
lineHeight: string;
|
|
858
|
+
};
|
|
859
|
+
useConnectedFontSize: {
|
|
860
|
+
fontSize: string;
|
|
861
|
+
lineHeight: string;
|
|
862
|
+
};
|
|
804
863
|
};
|
|
805
864
|
radii: {
|
|
806
865
|
actionButton: string;
|
|
@@ -822,6 +881,7 @@ export declare const useActiveTheme: () => {
|
|
|
822
881
|
dropdownList: string;
|
|
823
882
|
modalTopbarIcon: string;
|
|
824
883
|
withdrawalInput: string;
|
|
884
|
+
useConnected: string;
|
|
825
885
|
};
|
|
826
886
|
borderWidths: {
|
|
827
887
|
activeOptionBorderWidth: string;
|
|
@@ -884,6 +944,10 @@ export declare const useActiveTheme: () => {
|
|
|
884
944
|
youPayYouReceivePaddingLeft: string;
|
|
885
945
|
youPayYouReceivePaddingRight: string;
|
|
886
946
|
youPayYouReceivePaddingY: string;
|
|
947
|
+
inputPaddingX: string;
|
|
948
|
+
inputPaddingY: string;
|
|
949
|
+
dropdownActiveItemRegularSizePaddingY: string;
|
|
950
|
+
assetListDefaultGap: string;
|
|
887
951
|
};
|
|
888
952
|
textTransforms: {
|
|
889
953
|
inputAmountQuickOptionButton: string;
|
|
@@ -937,8 +1001,9 @@ export declare const useActiveTheme: () => {
|
|
|
937
1001
|
secondaryText: string;
|
|
938
1002
|
tertiaryText: string;
|
|
939
1003
|
textSelection: string;
|
|
940
|
-
|
|
1004
|
+
inputLabel: string;
|
|
941
1005
|
inputBackground: string;
|
|
1006
|
+
inputBackgroundHover: string;
|
|
942
1007
|
inputBorderBase: string;
|
|
943
1008
|
inputBorderHover: string;
|
|
944
1009
|
activeTabBorderColor: string;
|
|
@@ -1013,12 +1078,29 @@ export declare const useActiveTheme: () => {
|
|
|
1013
1078
|
fiatAccountGradientTo: string;
|
|
1014
1079
|
optionBoxBackground: string;
|
|
1015
1080
|
optionBoxBackgroundUninteractive: string;
|
|
1081
|
+
optionBoxBorderBase: string;
|
|
1016
1082
|
optionBoxBorderHover: string;
|
|
1083
|
+
optionBoxDefaultModeNotActiveBorderBase: string;
|
|
1084
|
+
optionBoxDefaultModeNotActiveBorderHover: string;
|
|
1017
1085
|
openDropdownBackgroundColor: string;
|
|
1018
1086
|
dropdownActiveItemBackgroundBase: string;
|
|
1019
1087
|
dropdownActiveItemBackgroundHover: string;
|
|
1020
1088
|
dropdownActiveItemBackgroundDisabled: string;
|
|
1089
|
+
dropdownActiveItemBorderBase: string;
|
|
1090
|
+
dropdownActiveItemBorderHover: string;
|
|
1021
1091
|
selectedDropdownItemBackground: string;
|
|
1092
|
+
alwaysVisibleLabelBackgroundHover: string;
|
|
1093
|
+
selectedDropdownItemText: string;
|
|
1094
|
+
dropdownLabelColor: string;
|
|
1095
|
+
copyButtonBackgroundBase: string;
|
|
1096
|
+
copyButtonBackgroundHover: string;
|
|
1097
|
+
copyButtonBackgroundActive: string;
|
|
1098
|
+
copyButtonBorderBase: string;
|
|
1099
|
+
copyButtonBorderHover: string;
|
|
1100
|
+
funFeatureListBackgroundBase: string;
|
|
1101
|
+
funFeatureListBackgroundHover: string;
|
|
1102
|
+
funFeatureListBorderColor: string;
|
|
1103
|
+
funFeatureListBorderColorHover: string;
|
|
1022
1104
|
spinnerBackground: string;
|
|
1023
1105
|
spinnerIndicator: string;
|
|
1024
1106
|
spinnerBackgroundVerifyAccount: string;
|
|
@@ -1046,6 +1128,7 @@ export declare const useActiveTheme: () => {
|
|
|
1046
1128
|
paymentAmountSkeletonCircleSize: string;
|
|
1047
1129
|
paymentMethodItemIconSize: string;
|
|
1048
1130
|
selectAssetItemIconSize: string;
|
|
1131
|
+
sourceListGap: string;
|
|
1049
1132
|
txBreakdownSkeletonWidth: string;
|
|
1050
1133
|
txSummaryLineSkeletonHeight: string;
|
|
1051
1134
|
txSummaryLineSkeletonWidth: string;
|
|
@@ -1241,6 +1324,14 @@ export declare const useActiveTheme: () => {
|
|
|
1241
1324
|
fontSize: string;
|
|
1242
1325
|
lineHeight: string;
|
|
1243
1326
|
};
|
|
1327
|
+
quickOptionFontSize: {
|
|
1328
|
+
fontSize: string;
|
|
1329
|
+
lineHeight: string;
|
|
1330
|
+
};
|
|
1331
|
+
useConnectedFontSize: {
|
|
1332
|
+
fontSize: string;
|
|
1333
|
+
lineHeight: string;
|
|
1334
|
+
};
|
|
1244
1335
|
};
|
|
1245
1336
|
radii: {
|
|
1246
1337
|
actionButton: string;
|
|
@@ -1262,6 +1353,7 @@ export declare const useActiveTheme: () => {
|
|
|
1262
1353
|
dropdownList: string;
|
|
1263
1354
|
modalTopbarIcon: string;
|
|
1264
1355
|
withdrawalInput: string;
|
|
1356
|
+
useConnected: string;
|
|
1265
1357
|
};
|
|
1266
1358
|
borderWidths: {
|
|
1267
1359
|
activeOptionBorderWidth: string;
|
|
@@ -1324,6 +1416,10 @@ export declare const useActiveTheme: () => {
|
|
|
1324
1416
|
youPayYouReceivePaddingLeft: string;
|
|
1325
1417
|
youPayYouReceivePaddingRight: string;
|
|
1326
1418
|
youPayYouReceivePaddingY: string;
|
|
1419
|
+
inputPaddingX: string;
|
|
1420
|
+
inputPaddingY: string;
|
|
1421
|
+
dropdownActiveItemRegularSizePaddingY: string;
|
|
1422
|
+
assetListDefaultGap: string;
|
|
1327
1423
|
};
|
|
1328
1424
|
textTransforms: {
|
|
1329
1425
|
inputAmountQuickOptionButton: string;
|
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
import { type FormOfPaymentType } from '@funkit/api-base';
|
|
1
2
|
import React from 'react';
|
|
2
3
|
import { type SwappedTheme } from '../utils/swapped';
|
|
3
4
|
export interface SwappedIframeCallbacks {
|
|
@@ -9,15 +10,14 @@ export interface SwappedIframeCallbacks {
|
|
|
9
10
|
onNavigation: (step: string) => void;
|
|
10
11
|
}
|
|
11
12
|
interface SwappedContextValue {
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
activateIframe: (
|
|
13
|
+
iframeUrl: string | null;
|
|
14
|
+
isSwappedReady: boolean;
|
|
15
|
+
isActive: boolean;
|
|
16
|
+
setIframeUrl: (url: string | null) => void;
|
|
17
|
+
activateIframe: (fopType: FormOfPaymentType) => void;
|
|
17
18
|
deactivateIframe: () => void;
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
setIframeRef: (url: string, el: HTMLIFrameElement | null) => void;
|
|
19
|
+
resetIframe: () => void;
|
|
20
|
+
setIframeRef: (el: HTMLIFrameElement | null) => void;
|
|
21
21
|
setActiveCallbacks: (cb: SwappedIframeCallbacks | null) => void;
|
|
22
22
|
swappedTheme: SwappedTheme;
|
|
23
23
|
}
|
package/dist/themes/baseTheme.js
CHANGED
package/dist/themes/darkTheme.js
CHANGED
package/dist/utils/checkout.d.ts
CHANGED
|
@@ -121,10 +121,10 @@ export declare function isVaultDepositCheckout(checkoutConfig: FunkitCheckoutCon
|
|
|
121
121
|
chainId: string;
|
|
122
122
|
tokenAddress: string;
|
|
123
123
|
}): boolean;
|
|
124
|
-
/** some additional
|
|
124
|
+
/** some additional finalized token will be performed after swap. We need to calculate the final destination token amount */
|
|
125
125
|
export declare function computeDisplayDestinationToken(checkoutConfig: FunkitCheckoutConfig | ServerCheckoutConfig | undefined, displayAssetAmount: number): {
|
|
126
|
-
|
|
127
|
-
|
|
128
|
-
|
|
126
|
+
finalizedTokenAmount: number;
|
|
127
|
+
finalizedTokenSymbol: string;
|
|
128
|
+
finalizedTokenIcon: string;
|
|
129
129
|
};
|
|
130
130
|
export {};
|
package/dist/utils/swapped.d.ts
CHANGED
|
@@ -1,5 +1,6 @@
|
|
|
1
|
-
import type
|
|
1
|
+
import { type SavedFormOfPayment, type SwappedFormOfPayment } from '@funkit/api-base';
|
|
2
2
|
import type { ThemeVars } from '../css/sprinkles.css';
|
|
3
|
+
import type { ThemeColorScheme } from '../providers/FunkitThemeProvider';
|
|
3
4
|
/**
|
|
4
5
|
* Ref: https://www.notion.so/Fun-Parameter-Styling-Guide-312966ea6e398011bbc6c14e976e281d#63dcdd77ea2d488084a980cda4c63d08
|
|
5
6
|
*/
|
|
@@ -25,10 +26,12 @@ export interface SwappedTheme {
|
|
|
25
26
|
contentPadding?: string;
|
|
26
27
|
boxPaddingY?: string;
|
|
27
28
|
boxPaddingX?: string;
|
|
29
|
+
paymentMethodLightLogos?: boolean;
|
|
28
30
|
}
|
|
29
31
|
export declare const isSavedFormOfPaymentType: (fop: SwappedFormOfPayment) => fop is SavedFormOfPayment;
|
|
30
32
|
export declare const getSavedFormOfPaymentDisplayName: (fop: SavedFormOfPayment) => string;
|
|
31
|
-
export declare const getSavedFormOfPaymentIcon: (fop: SavedFormOfPayment) => string;
|
|
33
|
+
export declare const getSavedFormOfPaymentIcon: (fop: SavedFormOfPayment) => string | undefined;
|
|
34
|
+
export declare const getSwappedIcon: (fop: SwappedFormOfPayment, isDarkMode: boolean) => string;
|
|
32
35
|
export declare function getSwappedOrigin(url: string): string | null;
|
|
33
36
|
export declare function isSwappedOrigin(origin: string): boolean;
|
|
34
37
|
export declare function resolveCssValue(value: string): string;
|
|
@@ -38,5 +41,5 @@ export declare function buildSwappedTheme(theme: ThemeVars & {
|
|
|
38
41
|
primary?: string;
|
|
39
42
|
secondary?: string;
|
|
40
43
|
};
|
|
41
|
-
}): SwappedTheme;
|
|
44
|
+
}, themeColorScheme: ThemeColorScheme): SwappedTheme;
|
|
42
45
|
export declare function buildSwappedThemeQueryParams(activeTheme: ThemeVars): Record<string, string>;
|
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
"use client";
|
|
2
2
|
import {
|
|
3
3
|
bifrostWallet
|
|
4
|
-
} from "../chunk-
|
|
5
|
-
import "../chunk-BAVE62IL.js";
|
|
4
|
+
} from "../chunk-EKJHJFRN.js";
|
|
6
5
|
import "../chunk-MAPXJUOO.js";
|
|
6
|
+
import "../chunk-BAVE62IL.js";
|
|
7
7
|
import "../chunk-KV4HGYM3.js";
|
|
8
8
|
export {
|
|
9
9
|
bifrostWallet
|
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
"use client";
|
|
2
2
|
import {
|
|
3
3
|
bitgetWallet
|
|
4
|
-
} from "../chunk-
|
|
5
|
-
import "../chunk-BAVE62IL.js";
|
|
4
|
+
} from "../chunk-HOPH3TQ3.js";
|
|
6
5
|
import "../chunk-MAPXJUOO.js";
|
|
6
|
+
import "../chunk-BAVE62IL.js";
|
|
7
7
|
import "../chunk-KV4HGYM3.js";
|
|
8
8
|
export {
|
|
9
9
|
bitgetWallet
|
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
"use client";
|
|
2
2
|
import {
|
|
3
3
|
bybitWallet
|
|
4
|
-
} from "../chunk-
|
|
5
|
-
import "../chunk-BAVE62IL.js";
|
|
4
|
+
} from "../chunk-6UCI7GM6.js";
|
|
6
5
|
import "../chunk-MAPXJUOO.js";
|
|
6
|
+
import "../chunk-BAVE62IL.js";
|
|
7
7
|
import "../chunk-KV4HGYM3.js";
|
|
8
8
|
export {
|
|
9
9
|
bybitWallet
|
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
"use client";
|
|
2
2
|
import {
|
|
3
3
|
coin98Wallet
|
|
4
|
-
} from "../chunk-
|
|
5
|
-
import "../chunk-BAVE62IL.js";
|
|
4
|
+
} from "../chunk-6YO27XOM.js";
|
|
6
5
|
import "../chunk-MAPXJUOO.js";
|
|
6
|
+
import "../chunk-BAVE62IL.js";
|
|
7
7
|
import "../chunk-KV4HGYM3.js";
|
|
8
8
|
export {
|
|
9
9
|
coin98Wallet
|
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
"use client";
|
|
2
2
|
import {
|
|
3
3
|
frontierWallet
|
|
4
|
-
} from "../chunk-
|
|
5
|
-
import "../chunk-BAVE62IL.js";
|
|
4
|
+
} from "../chunk-CJJT7LMT.js";
|
|
6
5
|
import "../chunk-MAPXJUOO.js";
|
|
6
|
+
import "../chunk-BAVE62IL.js";
|
|
7
7
|
import "../chunk-KV4HGYM3.js";
|
|
8
8
|
export {
|
|
9
9
|
frontierWallet
|