@symmio/trading-react 3.0.0 → 3.0.1-staging-20260926093035
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/estimated-price/use-estimated-price.d.ts +6 -3
- package/dist/estimated-price/use-estimated-price.d.ts.map +1 -1
- package/dist/estimated-price/use-estimated-price.js +12 -9
- package/dist/estimated-price/use-estimated-price.js.map +1 -1
- package/dist/index.d.ts +7 -7
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +169 -166
- package/dist/instant-layer/get-instant-open-funding-error.d.ts +5 -0
- package/dist/instant-layer/get-instant-open-funding-error.d.ts.map +1 -0
- package/dist/instant-layer/get-instant-open-funding-error.js +15 -0
- package/dist/instant-layer/get-instant-open-funding-error.js.map +1 -0
- package/dist/instant-layer/index.d.ts +2 -0
- package/dist/instant-layer/index.d.ts.map +1 -1
- package/dist/instant-layer/index.js +15 -13
- package/dist/instant-layer/use-instant-close-fees.d.ts +46 -0
- package/dist/instant-layer/use-instant-close-fees.d.ts.map +1 -0
- package/dist/instant-layer/use-instant-close-fees.js +83 -0
- package/dist/instant-layer/use-instant-close-fees.js.map +1 -0
- package/dist/instant-layer/use-instant-open-auto.d.ts +5 -0
- package/dist/instant-layer/use-instant-open-auto.d.ts.map +1 -1
- package/dist/instant-layer/use-instant-open-auto.js.map +1 -1
- package/dist/instant-layer/use-instant-open-fees.d.ts +33 -10
- package/dist/instant-layer/use-instant-open-fees.d.ts.map +1 -1
- package/dist/instant-layer/use-instant-open-fees.js +22 -98
- package/dist/instant-layer/use-instant-open-fees.js.map +1 -1
- package/dist/instant-layer/use-instant-open-inputs.d.ts +35 -0
- package/dist/instant-layer/use-instant-open-inputs.d.ts.map +1 -0
- package/dist/instant-layer/use-instant-open-inputs.js +134 -0
- package/dist/instant-layer/use-instant-open-inputs.js.map +1 -0
- package/dist/instant-layer/use-instant-open-with-tpsl.d.ts +6 -0
- package/dist/instant-layer/use-instant-open-with-tpsl.d.ts.map +1 -1
- package/dist/instant-layer/use-instant-open-with-tpsl.js.map +1 -1
- package/dist/instant-layer/use-prepare-instant-open-params.d.ts +69 -0
- package/dist/instant-layer/use-prepare-instant-open-params.d.ts.map +1 -0
- package/dist/instant-layer/use-prepare-instant-open-params.js +36 -0
- package/dist/instant-layer/use-prepare-instant-open-params.js.map +1 -0
- package/dist/margin/use-available-instant-open-margin.d.ts +3 -2
- package/dist/margin/use-available-instant-open-margin.d.ts.map +1 -1
- package/dist/margin/use-available-instant-open-margin.js +0 -1
- package/dist/margin/use-available-instant-open-margin.js.map +1 -1
- package/dist/solvers/index.d.ts +1 -0
- package/dist/solvers/index.d.ts.map +1 -1
- package/dist/solvers/use-solver-info.d.ts +14 -0
- package/dist/solvers/use-solver-info.d.ts.map +1 -0
- package/dist/solvers/use-solver-info.js +27 -0
- package/dist/solvers/use-solver-info.js.map +1 -0
- package/package.json +2 -2
package/dist/index.js
CHANGED
|
@@ -53,169 +53,172 @@ import { useInstantClose as Z } from "./instant-layer/use-instant-close.js";
|
|
|
53
53
|
import { useInstantCloseAuto as Q } from "./instant-layer/use-instant-close-auto.js";
|
|
54
54
|
import { useInstantCloseBulk as $ } from "./instant-layer/use-instant-close-bulk.js";
|
|
55
55
|
import { useInstantCloseBulkAuto as ee } from "./instant-layer/use-instant-close-bulk-auto.js";
|
|
56
|
-
import {
|
|
57
|
-
import {
|
|
58
|
-
import {
|
|
59
|
-
import {
|
|
60
|
-
import {
|
|
61
|
-
import {
|
|
62
|
-
import {
|
|
63
|
-
import {
|
|
64
|
-
import {
|
|
65
|
-
import {
|
|
66
|
-
import {
|
|
67
|
-
import {
|
|
68
|
-
import {
|
|
69
|
-
import {
|
|
70
|
-
import {
|
|
71
|
-
import {
|
|
72
|
-
import {
|
|
73
|
-
import {
|
|
74
|
-
import {
|
|
75
|
-
import {
|
|
76
|
-
import {
|
|
77
|
-
import {
|
|
78
|
-
import {
|
|
79
|
-
import {
|
|
80
|
-
import {
|
|
81
|
-
import {
|
|
82
|
-
import {
|
|
83
|
-
import {
|
|
84
|
-
import {
|
|
85
|
-
import {
|
|
86
|
-
import {
|
|
87
|
-
import {
|
|
88
|
-
import {
|
|
89
|
-
import {
|
|
90
|
-
import {
|
|
91
|
-
import {
|
|
92
|
-
import {
|
|
93
|
-
import {
|
|
94
|
-
import {
|
|
95
|
-
import {
|
|
96
|
-
import {
|
|
97
|
-
import {
|
|
98
|
-
import {
|
|
99
|
-
import {
|
|
100
|
-
import {
|
|
101
|
-
import {
|
|
102
|
-
import {
|
|
103
|
-
import {
|
|
104
|
-
import {
|
|
105
|
-
import {
|
|
106
|
-
import {
|
|
107
|
-
import {
|
|
108
|
-
import {
|
|
109
|
-
import {
|
|
110
|
-
import {
|
|
111
|
-
import {
|
|
112
|
-
import {
|
|
113
|
-
import {
|
|
114
|
-
import {
|
|
115
|
-
import {
|
|
116
|
-
import {
|
|
117
|
-
import {
|
|
118
|
-
import {
|
|
119
|
-
import {
|
|
120
|
-
import {
|
|
121
|
-
import {
|
|
122
|
-
import {
|
|
123
|
-
import {
|
|
124
|
-
import {
|
|
125
|
-
import {
|
|
126
|
-
import {
|
|
127
|
-
import {
|
|
128
|
-
import {
|
|
129
|
-
import {
|
|
130
|
-
import {
|
|
131
|
-
import {
|
|
132
|
-
import {
|
|
133
|
-
import {
|
|
134
|
-
import {
|
|
135
|
-
import {
|
|
136
|
-
import {
|
|
137
|
-
import {
|
|
138
|
-
import {
|
|
139
|
-
import {
|
|
140
|
-
import {
|
|
141
|
-
import {
|
|
142
|
-
import {
|
|
143
|
-
import {
|
|
144
|
-
import {
|
|
145
|
-
import {
|
|
146
|
-
import {
|
|
147
|
-
import {
|
|
148
|
-
import {
|
|
149
|
-
import {
|
|
150
|
-
import {
|
|
151
|
-
import {
|
|
152
|
-
import {
|
|
153
|
-
import {
|
|
154
|
-
import {
|
|
155
|
-
import {
|
|
156
|
-
import {
|
|
157
|
-
import {
|
|
158
|
-
import {
|
|
159
|
-
import {
|
|
160
|
-
import {
|
|
161
|
-
import {
|
|
162
|
-
import {
|
|
163
|
-
import {
|
|
164
|
-
import {
|
|
165
|
-
import {
|
|
166
|
-
import {
|
|
167
|
-
import {
|
|
168
|
-
import {
|
|
169
|
-
import {
|
|
170
|
-
import {
|
|
171
|
-
import {
|
|
172
|
-
import {
|
|
173
|
-
import {
|
|
174
|
-
import {
|
|
175
|
-
import {
|
|
176
|
-
import {
|
|
177
|
-
import {
|
|
178
|
-
import {
|
|
179
|
-
import {
|
|
180
|
-
import {
|
|
181
|
-
import {
|
|
182
|
-
import {
|
|
183
|
-
import {
|
|
184
|
-
import {
|
|
185
|
-
import {
|
|
186
|
-
import {
|
|
187
|
-
import {
|
|
188
|
-
import {
|
|
189
|
-
import {
|
|
190
|
-
import {
|
|
191
|
-
import {
|
|
192
|
-
import {
|
|
193
|
-
import {
|
|
194
|
-
import {
|
|
195
|
-
import {
|
|
196
|
-
import {
|
|
197
|
-
import {
|
|
198
|
-
import {
|
|
199
|
-
import {
|
|
200
|
-
import {
|
|
201
|
-
import {
|
|
202
|
-
import {
|
|
203
|
-
import {
|
|
204
|
-
import {
|
|
205
|
-
import {
|
|
206
|
-
import {
|
|
207
|
-
import {
|
|
208
|
-
import {
|
|
209
|
-
import {
|
|
210
|
-
import {
|
|
211
|
-
import {
|
|
212
|
-
import {
|
|
213
|
-
import {
|
|
214
|
-
import {
|
|
215
|
-
import {
|
|
216
|
-
import {
|
|
217
|
-
import {
|
|
218
|
-
import {
|
|
219
|
-
import {
|
|
220
|
-
import {
|
|
221
|
-
|
|
56
|
+
import { useFeeForUser as te } from "./fees/use-fee-for-user.js";
|
|
57
|
+
import { useMarkets as ne } from "./markets/use-markets.js";
|
|
58
|
+
import { usePrices as re } from "./price-service/use-prices.js";
|
|
59
|
+
import { usePriceByName as ie } from "./price-service/use-price-by-name.js";
|
|
60
|
+
import { useSolverInfo as ae } from "./solvers/use-solver-info.js";
|
|
61
|
+
import { useInstantCloseFees as oe } from "./instant-layer/use-instant-close-fees.js";
|
|
62
|
+
import { useInstantCloses as se } from "./instant-layer/use-instant-closes.js";
|
|
63
|
+
import { useInstantOpen as ce } from "./instant-layer/use-instant-open.js";
|
|
64
|
+
import { useInstantOpenAuto as le } from "./instant-layer/use-instant-open-auto.js";
|
|
65
|
+
import { useEstimatedPrice as ue } from "./estimated-price/use-estimated-price.js";
|
|
66
|
+
import { useLockedParams as de } from "./locked-params/use-locked-params.js";
|
|
67
|
+
import { useInstantOpenFees as fe } from "./instant-layer/use-instant-open-fees.js";
|
|
68
|
+
import { useInstantOpenQuoteId as pe } from "./instant-layer/use-instant-open-quote-id.js";
|
|
69
|
+
import { toQuoteTpSl as me } from "./tpsl/to-quote-tpsl.js";
|
|
70
|
+
import { useTpSlRecord as he, useTpSlRecords as ge, useTpSlStore as _e } from "./tpsl/tpsl-store.js";
|
|
71
|
+
import { useInstantOpenWithTpSl as ve } from "./instant-layer/use-instant-open-with-tpsl.js";
|
|
72
|
+
import { useInstantOpens as ye } from "./instant-layer/use-instant-opens.js";
|
|
73
|
+
import { useInstantTradeRequiredSelectors as be } from "./instant-layer/use-instant-trade-required-selectors.js";
|
|
74
|
+
import { useIsDelegationActive as xe } from "./instant-layer/use-is-delegation-active.js";
|
|
75
|
+
import { useLimitCloseAuto as Se } from "./instant-layer/use-limit-close-auto.js";
|
|
76
|
+
import { useLimitOpenAuto as Ce } from "./instant-layer/use-limit-open-auto.js";
|
|
77
|
+
import { usePrepareInstantOpenParams as we } from "./instant-layer/use-prepare-instant-open-params.js";
|
|
78
|
+
import { useSimulateGrantDelegation as Te } from "./instant-layer/use-simulate-grant-delegation.js";
|
|
79
|
+
import { useFinalizeWithdrawRequest as Ee } from "./withdraw/use-finalize-withdraw-request.js";
|
|
80
|
+
import { useInitiateWithdraw as De } from "./withdraw/use-initiate-withdraw.js";
|
|
81
|
+
import { useLastWithdrawRequestId as Oe } from "./withdraw/use-last-withdraw-request-id.js";
|
|
82
|
+
import { usePendingWithdrawRequests as ke } from "./withdraw/use-pending-withdraw-requests.js";
|
|
83
|
+
import { useRequestCancelWithdraw as Ae } from "./withdraw/use-request-cancel-withdraw.js";
|
|
84
|
+
import { useSimulateFinalizeWithdrawRequest as je } from "./withdraw/use-simulate-finalize-withdraw-request.js";
|
|
85
|
+
import { useSimulateInitiateWithdraw as Me } from "./withdraw/use-simulate-initiate-withdraw.js";
|
|
86
|
+
import { useSimulateRequestCancelWithdraw as Ne } from "./withdraw/use-simulate-request-cancel-withdraw.js";
|
|
87
|
+
import { useWithdraw as Pe } from "./withdraw/use-withdraw.js";
|
|
88
|
+
import { useWithdrawRequest as Fe } from "./withdraw/use-withdraw-requests.js";
|
|
89
|
+
import { useWithdrawableTime as Ie } from "./withdraw/use-withdrawable-time.js";
|
|
90
|
+
import { useOnchainContractMarkets as Le } from "./markets/use-onchain-contract-markets.js";
|
|
91
|
+
import { useSolverErrorCodes as Re } from "./error-codes/use-solver-error-codes.js";
|
|
92
|
+
import { useSolverErrorMessage as ze } from "./error-codes/use-solver-error-message.js";
|
|
93
|
+
import { useOptimisticQuotesStore as Be } from "./quotes/optimistic-quotes-store.js";
|
|
94
|
+
import { usePartyAOpenPositions as Ve } from "./quotes/use-party-a-open-positions.js";
|
|
95
|
+
import { useAccountLiquidationPrice as He } from "./quotes/use-account-liquidation-price.js";
|
|
96
|
+
import { useManagedQuotes as Ue } from "./quotes/use-managed-quotes.js";
|
|
97
|
+
import { useAccountUpnl as We } from "./quotes/use-account-upnl.js";
|
|
98
|
+
import { useCloseQuoteGroup as Ge } from "./quotes/use-close-quote-group.js";
|
|
99
|
+
import { useCoolDownsOfMA as Ke } from "./quotes/use-cool-downs-of-ma.js";
|
|
100
|
+
import { useForceCancelCloseRequest as qe } from "./quotes/use-force-cancel-close-request.js";
|
|
101
|
+
import { useForceCancelQuote as Je } from "./quotes/use-force-cancel-quote.js";
|
|
102
|
+
import { useForceClose as Ye } from "./quotes/use-force-close.js";
|
|
103
|
+
import { useSolverCapabilities as Xe, useSupportsGroupClose as Ze, useSupportsLimitOrder as Qe } from "./solvers/use-solver-capabilities.js";
|
|
104
|
+
import { useForceCloseParams as $e } from "./quotes/use-force-close-params.js";
|
|
105
|
+
import { useForceCloseEligibility as et } from "./quotes/use-force-close-eligibility.js";
|
|
106
|
+
import { useGroupedQuotes as tt } from "./quotes/use-grouped-quotes.js";
|
|
107
|
+
import { useLimitOrders as nt } from "./quotes/use-limit-orders.js";
|
|
108
|
+
import { usePartyAPendingQuotes as rt } from "./quotes/use-party-a-pending-quotes.js";
|
|
109
|
+
import { useQuote as it } from "./quotes/use-quote.js";
|
|
110
|
+
import { useQuoteEventsByType as at } from "./quotes/use-quote-events-by-type.js";
|
|
111
|
+
import { useQuotesFunding as ot } from "./quotes/use-quotes-funding.js";
|
|
112
|
+
import { useQuoteFunding as st } from "./quotes/use-quote-funding.js";
|
|
113
|
+
import { useQuoteGroupFunding as ct } from "./quotes/use-quote-group-funding.js";
|
|
114
|
+
import { useQuoteGroupFundingHistory as lt } from "./quotes/use-quote-group-funding-history.js";
|
|
115
|
+
import { useAccountMarginRisk as ut } from "./margin/use-account-margin-risk.js";
|
|
116
|
+
import { useEnigmaPriceByName as dt } from "./price-service/use-enigma-price-by-name.js";
|
|
117
|
+
import { useEnigmaPriceByMarketId as ft } from "./price-service/use-enigma-price-by-market-id.js";
|
|
118
|
+
import { useQuoteGroupMarginRisk as pt } from "./quotes/use-quote-group-margin-risk.js";
|
|
119
|
+
import { useQuoteHistory as mt } from "./quotes/use-quote-history.js";
|
|
120
|
+
import { useQuotePlatformFee as ht } from "./quotes/use-quote-platform-fee.js";
|
|
121
|
+
import { useQuotePriceHistory as gt } from "./quotes/use-quote-price-history.js";
|
|
122
|
+
import { usePriceByMarketId as _t } from "./price-service/use-price-by-market-id.js";
|
|
123
|
+
import { useQuoteUpnlAndPnl as vt } from "./quotes/use-quote-upnl-and-pnl.js";
|
|
124
|
+
import { useRequestToCancelCloseRequest as yt } from "./quotes/use-request-to-cancel-close-request.js";
|
|
125
|
+
import { useRequestToCancelQuote as bt } from "./quotes/use-request-to-cancel-quote.js";
|
|
126
|
+
import { useSubgraphQuery as xt } from "./quotes/use-subgraph-query.js";
|
|
127
|
+
import { useAvailableInstantOpenMargin as St } from "./margin/use-available-instant-open-margin.js";
|
|
128
|
+
import { useBalanceHistory as Ct } from "./balance-history/use-balance-history.js";
|
|
129
|
+
import { useDepositHistory as wt } from "./balance-history/use-deposit-history.js";
|
|
130
|
+
import { useWithdrawHistory as Tt } from "./balance-history/use-withdraw-history.js";
|
|
131
|
+
import { useTransferHistory as Et } from "./transfers/use-transfer-history.js";
|
|
132
|
+
import { DEFAULT_NOTIONAL_CAP_POLLING_MS as Dt, useNotionalCapBySymbolId as Ot } from "./notional-cap/use-notional-cap-by-symbol-id.js";
|
|
133
|
+
import { useNotionalCapAll as kt } from "./notional-cap/use-notional-cap-all.js";
|
|
134
|
+
import { useOpenInterestBySymbolId as At } from "./notional-cap/use-open-interest-by-symbol-id.js";
|
|
135
|
+
import { useFundingInfo as jt } from "./funding-info/use-funding-info.js";
|
|
136
|
+
import { useRevenueRecords as Mt } from "./revenue-records/use-revenue-records.js";
|
|
137
|
+
import { useSymbols as Nt } from "./symbols/use-symbols.js";
|
|
138
|
+
import { useTradeVolume as Pt } from "./trade-volume/use-trade-volume.js";
|
|
139
|
+
import { useMarketInfo as Ft } from "./market-info/use-market-info.js";
|
|
140
|
+
import { useSolverRevenue as It } from "./solvers/use-solver-revenue.js";
|
|
141
|
+
import { useBinanceHealth as Lt } from "./price-service/use-binance-health.js";
|
|
142
|
+
import { useBinancePremiumIndex as Rt } from "./price-service/use-binance-premium-index.js";
|
|
143
|
+
import { useBinancePrices as zt } from "./price-service/use-binance-prices.js";
|
|
144
|
+
import { useBinanceSymbolsInfo as Bt } from "./price-service/use-binance-symbols-info.js";
|
|
145
|
+
import { useEnigmaPriceServiceHealth as Vt } from "./price-service/use-enigma-price-service-health.js";
|
|
146
|
+
import { useEnigmaPriceServiceMetadata as Ht } from "./price-service/use-enigma-price-service-metadata.js";
|
|
147
|
+
import { useEnigmaPriceServicePricesByAddresses as Ut } from "./price-service/use-enigma-price-service-prices-by-addresses.js";
|
|
148
|
+
import { useEnigmaPriceServicePricesByNames as Wt } from "./price-service/use-enigma-price-service-prices-by-names.js";
|
|
149
|
+
import { useEnigmaPriceServiceSymbolsInfo as Gt } from "./price-service/use-enigma-price-service-symbols-info.js";
|
|
150
|
+
import { useEnigmaPrices as Kt } from "./price-service/use-enigma-prices.js";
|
|
151
|
+
import { useMarkPrices as qt } from "./price-service/use-mark-prices.js";
|
|
152
|
+
import { useSearchNotifications as Jt } from "./notifications/use-search-notifications.js";
|
|
153
|
+
import { useDeallocateUpnlSig as Yt } from "./muon/use-deallocate-upnl-sig.js";
|
|
154
|
+
import { useForceClosePriceSig as Xt } from "./muon/use-force-close-price-sig.js";
|
|
155
|
+
import { useMuonPartyAOverview as Zt } from "./muon/use-muon-party-a-overview.js";
|
|
156
|
+
import { useMuonPrice as Qt } from "./muon/use-muon-price.js";
|
|
157
|
+
import { useMuonPriceRange as $t } from "./muon/use-muon-price-range.js";
|
|
158
|
+
import { useMuonSettleUpnl as en } from "./muon/use-muon-settle-upnl.js";
|
|
159
|
+
import { useMuonUpnl as tn } from "./muon/use-muon-upnl.js";
|
|
160
|
+
import { useMuonUpnlA as nn } from "./muon/use-muon-upnl-a.js";
|
|
161
|
+
import { useMuonUpnlAWithSymbolPrice as rn } from "./muon/use-muon-upnl-a-with-symbol-price.js";
|
|
162
|
+
import { useMuonUpnlB as an } from "./muon/use-muon-upnl-b.js";
|
|
163
|
+
import { useMuonUpnlWithSymbolPrice as on } from "./muon/use-muon-upnl-with-symbol-price.js";
|
|
164
|
+
import { useSendQuoteUpnlSig as sn } from "./muon/use-send-quote-upnl-sig.js";
|
|
165
|
+
import { invalidateTpSlReads as cn } from "./tpsl/invalidate-tpsl.js";
|
|
166
|
+
import { useDeleteQuoteGroupTpSl as ln } from "./tpsl/use-delete-quote-group-tpsl.js";
|
|
167
|
+
import { useDeleteQuoteTpSl as un } from "./tpsl/use-delete-quote-tpsl.js";
|
|
168
|
+
import { useQuoteGroupTpSl as dn } from "./tpsl/use-quote-group-tpsl.js";
|
|
169
|
+
import { useQuoteGroupTpSlEditor as fn } from "./tpsl/use-quote-group-tpsl-editor.js";
|
|
170
|
+
import { useWatchTpSlNotifications as pn } from "./tpsl/use-watch-tpsl-notifications.js";
|
|
171
|
+
import { useQuoteTpSl as mn } from "./tpsl/use-quote-tpsl.js";
|
|
172
|
+
import { useSearchTpSlOrders as hn } from "./tpsl/use-search-tpsl-orders.js";
|
|
173
|
+
import { useSetQuoteGroupTpSl as gn } from "./tpsl/use-set-quote-group-tpsl.js";
|
|
174
|
+
import { useSetQuoteTpSl as _n } from "./tpsl/use-set-quote-tpsl.js";
|
|
175
|
+
import { useTpSlConfig as vn } from "./tpsl/use-tpsl-config.js";
|
|
176
|
+
import { useTpSlSigningSpec as yn } from "./tpsl/use-tpsl-signing-spec.js";
|
|
177
|
+
import { useTpSlSupported as bn } from "./tpsl/use-tpsl-supported.js";
|
|
178
|
+
import { useBinanceCandleSource as xn } from "./candles/use-binance-candle-source.js";
|
|
179
|
+
import { useCandleStream as Sn } from "./candles/use-candle-stream.js";
|
|
180
|
+
import { useCandles as Cn } from "./candles/use-candles.js";
|
|
181
|
+
import { useTradingViewDatafeed as wn } from "./candles/use-tradingview-datafeed.js";
|
|
182
|
+
import { useBinanceOrderbookSource as Tn } from "./orderbook/use-binance-orderbook-source.js";
|
|
183
|
+
import { useOrderbookStream as En } from "./orderbook/use-orderbook-stream.js";
|
|
184
|
+
import { useLiveOrderbook as Dn } from "./orderbook/use-live-orderbook.js";
|
|
185
|
+
import { useOrderbook as On } from "./orderbook/use-orderbook.js";
|
|
186
|
+
import { useErrorMessage as kn } from "./rasa-solver/use-error-message.js";
|
|
187
|
+
import { usePartyAUpnl as An } from "./rasa-solver/use-party-a-upnl.js";
|
|
188
|
+
import { useSolverBalanceInfo as jn } from "./rasa-solver/use-solver-balance-info.js";
|
|
189
|
+
import { useSolverOpenInterest as Mn } from "./rasa-solver/use-solver-open-interest.js";
|
|
190
|
+
import { useSolverPriceRange as Nn } from "./rasa-solver/use-solver-price-range.js";
|
|
191
|
+
import { useSolverReadiness as Pn } from "./rasa-solver/use-solver-readiness.js";
|
|
192
|
+
import { useAddMarket as Fn } from "./pools/use-add-market.js";
|
|
193
|
+
import { useAuthenticateListing as In } from "./pools/use-authenticate-listing.js";
|
|
194
|
+
import { useCancelWithdraw as Ln } from "./pools/use-cancel-withdraw.js";
|
|
195
|
+
import { useClaimHistory as Rn } from "./pools/use-claim-history.js";
|
|
196
|
+
import { useClaimProfit as zn } from "./pools/use-claim-profit.js";
|
|
197
|
+
import { useDepositAddress as Bn } from "./pools/use-deposit-address.js";
|
|
198
|
+
import { useListingConfig as Vn } from "./pools/use-listing-config.js";
|
|
199
|
+
import { useListingMarketConfig as Hn } from "./pools/use-listing-market-config.js";
|
|
200
|
+
import { useListingMarketDetail as Un } from "./pools/use-listing-market-detail.js";
|
|
201
|
+
import { useUserProfit as Wn } from "./pools/use-user-profit.js";
|
|
202
|
+
import { useListingMarketConfigProjection as Gn } from "./pools/use-listing-market-config-projection.js";
|
|
203
|
+
import { useListingMarkets as Kn } from "./pools/use-listing-markets.js";
|
|
204
|
+
import { useListingStatus as qn } from "./pools/use-listing-status.js";
|
|
205
|
+
import { usePoolQuotes as Jn } from "./pools/use-pool-quotes.js";
|
|
206
|
+
import { usePoolRewardChart as Yn } from "./pools/use-pool-reward-chart.js";
|
|
207
|
+
import { usePoolTotalReward as Xn } from "./pools/use-pool-total-reward.js";
|
|
208
|
+
import { usePoolTradeHistory as Zn } from "./pools/use-pool-trade-history.js";
|
|
209
|
+
import { usePoolTransactions as Qn } from "./pools/use-pool-transactions.js";
|
|
210
|
+
import { useRefundMarket as $n } from "./pools/use-refund-market.js";
|
|
211
|
+
import { useRetryListing as er } from "./pools/use-retry-listing.js";
|
|
212
|
+
import { useRetryListingInfo as tr } from "./pools/use-retry-listing-info.js";
|
|
213
|
+
import { useSupportsListingService as nr } from "./pools/use-supports-listing-service.js";
|
|
214
|
+
import { useUpdateListingMarketConfig as rr } from "./pools/use-update-listing-market-config.js";
|
|
215
|
+
import { useUserListingMarkets as ir } from "./pools/use-user-listing-markets.js";
|
|
216
|
+
import { useUserRewardChart as ar } from "./pools/use-user-reward-chart.js";
|
|
217
|
+
import { useUserTotalReward as or } from "./pools/use-user-total-reward.js";
|
|
218
|
+
import { useUserTransactions as sr } from "./pools/use-user-transactions.js";
|
|
219
|
+
import { useWeeklyListingLimit as cr } from "./pools/use-weekly-listing-limit.js";
|
|
220
|
+
import { useWithdrawLp as lr } from "./pools/use-withdraw-lp.js";
|
|
221
|
+
import { useInventoryTvl as ur } from "./inventory/use-inventory-tvl.js";
|
|
222
|
+
import { useInventoryTvlHistory as dr } from "./inventory/use-inventory-tvl-history.js";
|
|
223
|
+
import { ADD_MARGIN_TO_NEXT_VA_SELECTOR as fr, DEFAULT_TPSL_SLIPPAGE_LOWCAPS as pr, GROUP_TPSL_SIDES as mr, INSTANT_TRADE_REQUIRED_SELECTORS as hr, LEGACY_INSTANT_TRADE_REQUIRED_SELECTORS as gr, NotificationType as _r, OrderType as vr, PositionType as yr, QuoteStatus as br, REQUEST_TO_CLOSE_POSITION_SELECTOR as xr, SEND_QUOTE_SELECTOR as Sr, SEND_QUOTE_WITH_AFFILIATE_AND_DATA_SELECTOR as Cr, SubAccountIsolationType as wr, SymmApiError as Tr, SymmError as Er, VIRTUAL_ACCOUNT_ISOLATION_TYPE as Dr, ZERO_LEG as Or, buildConditionalOrderLeg as kr, buildConditionalOrderMessage as Ar, buildTpSlDeleteMessage as jr, calculateAvailableForOrder as Mr, calculateAvailableInstantOpenMargin as Nr, calculateClosePrice as Pr, calculatePriceImpact as Fr, calculateQuoteLeverage as Ir, calculateQuotePnl as Lr, calculateSolverCloseFee as Rr, calculateTradeParams as zr, childNotional as Br, clampClosePrecision as Vr, decimalPriceToWei as Hr, deleteQuoteTpSl as Ur, deleteQuoteTpSlMutationOptions as Wr, estimateGroupTpSlReturn as Gr, generateTpSlSalt as Kr, getPartyAOpenPositionsQueryKey as qr, getPartyAOpenPositionsQueryOptions as Jr, isolationTypeForSide as Yr, parseTpSlFrame as Xr, planGroupTpSl as Zr, planGroupTpSlDelete as Qr, priceSlippageCalculation as $r, sharePercent as ei, signTpSlRequest as ti, summarizeQuoteGroupTpSl as ni, supportsEstimatedPrice as ri, toGroupTpSlChildren as ii, toGroupTpSlOrders as ai, toSignableTpSlMessage as oi, validateInstantCloseAgainstMarket as si, validateInstantOpenAgainstMarket as ci, validateTpSl as li, watchTpSlNotifications as ui } from "@symmio/trading-core";
|
|
224
|
+
export { fr as ADD_MARGIN_TO_NEXT_VA_SELECTOR, Dt as DEFAULT_NOTIONAL_CAP_POLLING_MS, pr as DEFAULT_TPSL_SLIPPAGE_LOWCAPS, mr as GROUP_TPSL_SIDES, hr as INSTANT_TRADE_REQUIRED_SELECTORS, gr as LEGACY_INSTANT_TRADE_REQUIRED_SELECTORS, _r as NotificationType, vr as OrderType, yr as PositionType, br as QuoteStatus, xr as REQUEST_TO_CLOSE_POSITION_SELECTOR, Sr as SEND_QUOTE_SELECTOR, Cr as SEND_QUOTE_WITH_AFFILIATE_AND_DATA_SELECTOR, wr as SubAccountIsolationType, Tr as SymmApiError, Er as SymmError, e as SymmioProvider, r as SymmioRequestError, Dr as VIRTUAL_ACCOUNT_ISOLATION_TYPE, Or as ZERO_LEG, kr as buildConditionalOrderLeg, Ar as buildConditionalOrderMessage, jr as buildTpSlDeleteMessage, Mr as calculateAvailableForOrder, Nr as calculateAvailableInstantOpenMargin, Pr as calculateClosePrice, Fr as calculatePriceImpact, Ir as calculateQuoteLeverage, Lr as calculateQuotePnl, Rr as calculateSolverCloseFee, zr as calculateTradeParams, Br as childNotional, Vr as clampClosePrecision, Hr as decimalPriceToWei, Ur as deleteQuoteTpSl, Wr as deleteQuoteTpSlMutationOptions, Gr as estimateGroupTpSlReturn, Kr as generateTpSlSalt, qr as getPartyAOpenPositionsQueryKey, Jr as getPartyAOpenPositionsQueryOptions, cn as invalidateTpSlReads, Yr as isolationTypeForSide, i as normalizeSymmError, Xr as parseTpSlFrame, Zr as planGroupTpSl, Qr as planGroupTpSlDelete, p as predicateMatch, $r as priceSlippageCalculation, ei as sharePercent, ti as signTpSlRequest, ni as summarizeQuoteGroupTpSl, ri as supportsEstimatedPrice, ii as toGroupTpSlChildren, ai as toGroupTpSlOrders, me as toQuoteTpSl, oi as toSignableTpSlMessage, u as useAccountBalanceInfo, d as useAccountBalanceOf, He as useAccountLiquidationPrice, ut as useAccountMarginRisk, We as useAccountUpnl, m as useAddMargin, Fn as useAddMarket, h as useAffiliateState, g as useAllocate, G as useApproveCollateral, In as useAuthenticateListing, St as useAvailableInstantOpenMargin, Ct as useBalanceHistory, xn as useBinanceCandleSource, Lt as useBinanceHealth, Tn as useBinanceOrderbookSource, Rt as useBinancePremiumIndex, zt as useBinancePrices, Bt as useBinanceSymbolsInfo, _ as useCancelRegistration, Ln as useCancelWithdraw, Sn as useCandleStream, Cn as useCandles, Rn as useClaimHistory, zn as useClaimProfit, Ge as useCloseQuoteGroup, K as useCollateralAllowance, q as useCollateralBalance, a as useConnectWallet, Ke as useCoolDownsOfMA, v as useCreateSubAccounts, y as useDeallocate, b as useDeallocateAndInitiateWithdraw, Yt as useDeallocateUpnlSig, Y as useDelegationExpiry, ln as useDeleteQuoteGroupTpSl, un as useDeleteQuoteTpSl, x as useDeleteSubAccount, S as useDeposit, Bn as useDepositAddress, C as useDepositAndAllocate, wt as useDepositHistory, o as useDisconnectWallet, w as useEditAccountName, ft as useEnigmaPriceByMarketId, dt as useEnigmaPriceByName, Vt as useEnigmaPriceServiceHealth, Ht as useEnigmaPriceServiceMetadata, Ut as useEnigmaPriceServicePricesByAddresses, Wt as useEnigmaPriceServicePricesByNames, Gt as useEnigmaPriceServiceSymbolsInfo, Kt as useEnigmaPrices, kn as useErrorMessage, ue as useEstimatedPrice, te as useFeeForUser, Ee as useFinalizeWithdrawRequest, qe as useForceCancelCloseRequest, Je as useForceCancelQuote, Ye as useForceClose, et as useForceCloseEligibility, $e as useForceCloseParams, Xt as useForceClosePriceSig, jt as useFundingInfo, T as useGeneratedAccountManagerAddress, X as useGrantDelegation, tt as useGroupedQuotes, De as useInitiateWithdraw, Z as useInstantClose, Q as useInstantCloseAuto, $ as useInstantCloseBulk, ee as useInstantCloseBulkAuto, oe as useInstantCloseFees, se as useInstantCloses, ce as useInstantOpen, le as useInstantOpenAuto, fe as useInstantOpenFees, pe as useInstantOpenQuoteId, ve as useInstantOpenWithTpSl, ye as useInstantOpens, be as useInstantTradeRequiredSelectors, ur as useInventoryTvl, dr as useInventoryTvlHistory, xe as useIsDelegationActive, Oe as useLastWithdrawRequestId, Se as useLimitCloseAuto, Ce as useLimitOpenAuto, nt as useLimitOrders, Vn as useListingConfig, Hn as useListingMarketConfig, Gn as useListingMarketConfigProjection, Un as useListingMarketDetail, Kn as useListingMarkets, qn as useListingStatus, Dn as useLiveOrderbook, de as useLockedParams, Ue as useManagedQuotes, qt as useMarkPrices, Ft as useMarketInfo, ne as useMarkets, Zt as useMuonPartyAOverview, Qt as useMuonPrice, $t as useMuonPriceRange, en as useMuonSettleUpnl, tn as useMuonUpnl, nn as useMuonUpnlA, rn as useMuonUpnlAWithSymbolPrice, an as useMuonUpnlB, on as useMuonUpnlWithSymbolPrice, l as useNotifications, kt as useNotionalCapAll, Ot as useNotionalCapBySymbolId, Le as useOnchainContractMarkets, At as useOpenInterestBySymbolId, Be as useOptimisticQuotesStore, On as useOrderbook, En as useOrderbookStream, Ve as usePartyAOpenPositions, rt as usePartyAPendingQuotes, An as usePartyAUpnl, ke as usePendingWithdrawRequests, Jn as usePoolQuotes, Yn as usePoolRewardChart, Xn as usePoolTotalReward, Zn as usePoolTradeHistory, Qn as usePoolTransactions, E as usePredictedNextVirtualAccount, we as usePrepareInstantOpenParams, _t as usePriceByMarketId, ie as usePriceByName, re as usePrices, it as useQuote, at as useQuoteEventsByType, st as useQuoteFunding, ct as useQuoteGroupFunding, lt as useQuoteGroupFundingHistory, pt as useQuoteGroupMarginRisk, dn as useQuoteGroupTpSl, fn as useQuoteGroupTpSlEditor, mt as useQuoteHistory, ht as useQuotePlatformFee, gt as useQuotePriceHistory, mn as useQuoteTpSl, vt as useQuoteUpnlAndPnl, ot as useQuotesFunding, $n as useRefundMarket, D as useRemoveMargin, Ae as useRequestCancelWithdraw, yt as useRequestToCancelCloseRequest, bt as useRequestToCancelQuote, O as useRequestToRegisterAffiliate, er as useRetryListing, tr as useRetryListingInfo, Mt as useRevenueRecords, Jt as useSearchNotifications, hn as useSearchTpSlOrders, sn as useSendQuoteUpnlSig, gn as useSetQuoteGroupTpSl, _n as useSetQuoteTpSl, k as useSimulateAddMargin, A as useSimulateAllocate, J as useSimulateApproveCollateral, j as useSimulateCreateSubAccounts, M as useSimulateDeallocate, N as useSimulateDeleteSubAccount, P as useSimulateDeposit, F as useSimulateDepositAndAllocate, I as useSimulateEditAccountName, je as useSimulateFinalizeWithdrawRequest, Te as useSimulateGrantDelegation, Me as useSimulateInitiateWithdraw, L as useSimulateRemoveMargin, Ne as useSimulateRequestCancelWithdraw, jn as useSolverBalanceInfo, Xe as useSolverCapabilities, Re as useSolverErrorCodes, ze as useSolverErrorMessage, ae as useSolverInfo, Mn as useSolverOpenInterest, Nn as useSolverPriceRange, Pn as useSolverReadiness, It as useSolverRevenue, R as useSubAccount, z as useSubAccountVirtualNonce, B as useSubAccountsCountOfUser, xt as useSubgraphQuery, Ze as useSupportsGroupClose, Qe as useSupportsLimitOrder, nr as useSupportsListingService, s as useSwitchToSymmioChain, Nt as useSymbols, t as useSymmioChainId, n as useSymmioConfig, vn as useTpSlConfig, he as useTpSlRecord, ge as useTpSlRecords, yn as useTpSlSigningSpec, _e as useTpSlStore, bn as useTpSlSupported, Pt as useTradeVolume, wn as useTradingViewDatafeed, f as useTransactionsStore, Et as useTransferHistory, rr as useUpdateListingMarketConfig, ir as useUserListingMarkets, Wn as useUserProfit, ar as useUserRewardChart, V as useUserSubAccounts, H as useUserSubAccountsAddresses, or as useUserTotalReward, sr as useUserTransactions, U as useVirtualAccount, W as useVirtualAccountsAddressesOfSubAccount, c as useWalletAccount, pn as useWatchTpSlNotifications, cr as useWeeklyListingLimit, Pe as useWithdraw, Tt as useWithdrawHistory, lr as useWithdrawLp, Fe as useWithdrawRequest, Ie as useWithdrawableTime, si as validateInstantCloseAgainstMarket, ci as validateInstantOpenAgainstMarket, li as validateTpSl, ui as watchTpSlNotifications };
|
|
@@ -0,0 +1,5 @@
|
|
|
1
|
+
import { validateInstantOpenBalanceFunding } from '@symmio/trading-core';
|
|
2
|
+
import { SymmioRequestError } from '../errors/symmio-request-error.js';
|
|
3
|
+
/** Run core's synchronous funding check before enabling dependent React queries. */
|
|
4
|
+
export declare function getInstantOpenFundingError(parameters: Parameters<typeof validateInstantOpenBalanceFunding>[0]): SymmioRequestError | undefined;
|
|
5
|
+
//# sourceMappingURL=get-instant-open-funding-error.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"get-instant-open-funding-error.d.ts","sourceRoot":"","sources":["../../src/instant-layer/get-instant-open-funding-error.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,iCAAiC,EAAE,MAAM,sBAAsB,CAAC;AAEzE,OAAO,KAAK,EAAE,kBAAkB,EAAE,MAAM,gCAAgC,CAAC;AAEzE,oFAAoF;AACpF,wBAAgB,0BAA0B,CACxC,UAAU,EAAE,UAAU,CAAC,OAAO,iCAAiC,CAAC,CAAC,CAAC,CAAC,GAClE,kBAAkB,GAAG,SAAS,CAOhC"}
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
import { normalizeSymmError as e } from "../errors/normalize-symm-error.js";
|
|
2
|
+
import { validateInstantOpenBalanceFunding as t } from "@symmio/trading-core";
|
|
3
|
+
//#region src/instant-layer/get-instant-open-funding-error.ts
|
|
4
|
+
function n(n) {
|
|
5
|
+
try {
|
|
6
|
+
t(n);
|
|
7
|
+
return;
|
|
8
|
+
} catch (t) {
|
|
9
|
+
return e(t);
|
|
10
|
+
}
|
|
11
|
+
}
|
|
12
|
+
//#endregion
|
|
13
|
+
export { n as getInstantOpenFundingError };
|
|
14
|
+
|
|
15
|
+
//# sourceMappingURL=get-instant-open-funding-error.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"get-instant-open-funding-error.js","names":[],"sources":["../../src/instant-layer/get-instant-open-funding-error.ts"],"sourcesContent":["import { validateInstantOpenBalanceFunding } from \"@symmio/trading-core\";\nimport { normalizeSymmError } from \"../errors/normalize-symm-error\";\nimport type { SymmioRequestError } from \"../errors/symmio-request-error\";\n\n/** Run core's synchronous funding check before enabling dependent React queries. */\nexport function getInstantOpenFundingError(\n parameters: Parameters<typeof validateInstantOpenBalanceFunding>[0],\n): SymmioRequestError | undefined {\n try {\n validateInstantOpenBalanceFunding(parameters);\n return undefined;\n } catch (error) {\n return normalizeSymmError(error);\n }\n}\n"],"mappings":";;;AAKA,SAAgB,EACd,GACgC;CAChC,IAAI;EACF,EAAkC,CAAU;EAC5C;CACF,SAAS,GAAO;EACd,OAAO,EAAmB,CAAK;CACjC;AACF"}
|
|
@@ -4,6 +4,7 @@ export * from './use-instant-close.js';
|
|
|
4
4
|
export * from './use-instant-close-auto.js';
|
|
5
5
|
export * from './use-instant-close-bulk.js';
|
|
6
6
|
export * from './use-instant-close-bulk-auto.js';
|
|
7
|
+
export * from './use-instant-close-fees.js';
|
|
7
8
|
export * from './use-instant-closes.js';
|
|
8
9
|
export * from './use-instant-open.js';
|
|
9
10
|
export * from './use-instant-open-auto.js';
|
|
@@ -15,5 +16,6 @@ export * from './use-instant-trade-required-selectors.js';
|
|
|
15
16
|
export * from './use-is-delegation-active.js';
|
|
16
17
|
export * from './use-limit-close-auto.js';
|
|
17
18
|
export * from './use-limit-open-auto.js';
|
|
19
|
+
export * from './use-prepare-instant-open-params.js';
|
|
18
20
|
export * from './use-simulate-grant-delegation.js';
|
|
19
21
|
//# sourceMappingURL=index.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/instant-layer/index.ts"],"names":[],"mappings":"AAAA,cAAc,yBAAyB,CAAC;AACxC,cAAc,wBAAwB,CAAC;AACvC,cAAc,qBAAqB,CAAC;AACpC,cAAc,0BAA0B,CAAC;AACzC,cAAc,0BAA0B,CAAC;AACzC,cAAc,+BAA+B,CAAC;AAC9C,cAAc,sBAAsB,CAAC;AACrC,cAAc,oBAAoB,CAAC;AACnC,cAAc,yBAAyB,CAAC;AACxC,cAAc,yBAAyB,CAAC;AACxC,cAAc,6BAA6B,CAAC;AAC5C,cAAc,8BAA8B,CAAC;AAC7C,cAAc,qBAAqB,CAAC;AACpC,cAAc,wCAAwC,CAAC;AACvD,cAAc,4BAA4B,CAAC;AAC3C,cAAc,wBAAwB,CAAC;AACvC,cAAc,uBAAuB,CAAC;AACtC,cAAc,iCAAiC,CAAC"}
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/instant-layer/index.ts"],"names":[],"mappings":"AAAA,cAAc,yBAAyB,CAAC;AACxC,cAAc,wBAAwB,CAAC;AACvC,cAAc,qBAAqB,CAAC;AACpC,cAAc,0BAA0B,CAAC;AACzC,cAAc,0BAA0B,CAAC;AACzC,cAAc,+BAA+B,CAAC;AAC9C,cAAc,0BAA0B,CAAC;AACzC,cAAc,sBAAsB,CAAC;AACrC,cAAc,oBAAoB,CAAC;AACnC,cAAc,yBAAyB,CAAC;AACxC,cAAc,yBAAyB,CAAC;AACxC,cAAc,6BAA6B,CAAC;AAC5C,cAAc,8BAA8B,CAAC;AAC7C,cAAc,qBAAqB,CAAC;AACpC,cAAc,wCAAwC,CAAC;AACvD,cAAc,4BAA4B,CAAC;AAC3C,cAAc,wBAAwB,CAAC;AACvC,cAAc,uBAAuB,CAAC;AACtC,cAAc,mCAAmC,CAAC;AAClD,cAAc,iCAAiC,CAAC"}
|
|
@@ -4,16 +4,18 @@ import { useInstantClose as n } from "./use-instant-close.js";
|
|
|
4
4
|
import { useInstantCloseAuto as r } from "./use-instant-close-auto.js";
|
|
5
5
|
import { useInstantCloseBulk as i } from "./use-instant-close-bulk.js";
|
|
6
6
|
import { useInstantCloseBulkAuto as a } from "./use-instant-close-bulk-auto.js";
|
|
7
|
-
import {
|
|
8
|
-
import {
|
|
9
|
-
import {
|
|
10
|
-
import {
|
|
11
|
-
import {
|
|
12
|
-
import {
|
|
13
|
-
import {
|
|
14
|
-
import {
|
|
15
|
-
import {
|
|
16
|
-
import {
|
|
17
|
-
import {
|
|
18
|
-
import {
|
|
19
|
-
|
|
7
|
+
import { useInstantCloseFees as o } from "./use-instant-close-fees.js";
|
|
8
|
+
import { useInstantCloses as s } from "./use-instant-closes.js";
|
|
9
|
+
import { useInstantOpen as c } from "./use-instant-open.js";
|
|
10
|
+
import { useInstantOpenAuto as l } from "./use-instant-open-auto.js";
|
|
11
|
+
import { useInstantOpenFees as u } from "./use-instant-open-fees.js";
|
|
12
|
+
import { useInstantOpenQuoteId as d } from "./use-instant-open-quote-id.js";
|
|
13
|
+
import { useInstantOpenWithTpSl as f } from "./use-instant-open-with-tpsl.js";
|
|
14
|
+
import { useInstantOpens as p } from "./use-instant-opens.js";
|
|
15
|
+
import { useInstantTradeRequiredSelectors as m } from "./use-instant-trade-required-selectors.js";
|
|
16
|
+
import { useIsDelegationActive as h } from "./use-is-delegation-active.js";
|
|
17
|
+
import { useLimitCloseAuto as g } from "./use-limit-close-auto.js";
|
|
18
|
+
import { useLimitOpenAuto as _ } from "./use-limit-open-auto.js";
|
|
19
|
+
import { usePrepareInstantOpenParams as v } from "./use-prepare-instant-open-params.js";
|
|
20
|
+
import { useSimulateGrantDelegation as y } from "./use-simulate-grant-delegation.js";
|
|
21
|
+
export { e as useDelegationExpiry, t as useGrantDelegation, n as useInstantClose, r as useInstantCloseAuto, i as useInstantCloseBulk, a as useInstantCloseBulkAuto, o as useInstantCloseFees, s as useInstantCloses, c as useInstantOpen, l as useInstantOpenAuto, u as useInstantOpenFees, d as useInstantOpenQuoteId, f as useInstantOpenWithTpSl, p as useInstantOpens, m as useInstantTradeRequiredSelectors, h as useIsDelegationActive, g as useLimitCloseAuto, _ as useLimitOpenAuto, v as usePrepareInstantOpenParams, y as useSimulateGrantDelegation };
|
|
@@ -0,0 +1,46 @@
|
|
|
1
|
+
import { ConfigParameter, GetInstantCloseFeesOptions, GetInstantCloseFeesReturnType } from '@symmio/trading-core';
|
|
2
|
+
import { UseQueryResult } from '@tanstack/react-query';
|
|
3
|
+
import { SymmioRequestError } from '../errors/symmio-request-error.js';
|
|
4
|
+
/**
|
|
5
|
+
* Parameters for {@link useInstantCloseFees}: the close intent
|
|
6
|
+
* (`subAccountAddress`, `market`, `quantity`, `openedAt`, optional pre-fetched
|
|
7
|
+
* data, TanStack `query` overrides) plus an optional `config`.
|
|
8
|
+
*/
|
|
9
|
+
export type UseInstantCloseFeesParameters = GetInstantCloseFeesOptions & ConfigParameter;
|
|
10
|
+
/** Return type of {@link useInstantCloseFees}. */
|
|
11
|
+
export type UseInstantCloseFeesReturnType = UseQueryResult<GetInstantCloseFeesReturnType, SymmioRequestError>;
|
|
12
|
+
/**
|
|
13
|
+
* Preview every fee closing a position pays **right now** — the platform close
|
|
14
|
+
* fee plus, on lowcap (Enigma), the holding-time solver close fee and the flat
|
|
15
|
+
* static close leg. Read-only; nothing is signed. This is the close-flow
|
|
16
|
+
* counterpart of `useInstantOpenFees`, which deliberately previews only the
|
|
17
|
+
* open-side legs: the honest close cost exists only at close time, where the
|
|
18
|
+
* notional and the decaying solver rate are real.
|
|
19
|
+
*
|
|
20
|
+
* Wraps `getInstantCloseFees`, but **pre-fetches every input through its own
|
|
21
|
+
* cached queries and passes them in as prefills**, so the query function is
|
|
22
|
+
* pure math with zero network hops: market metadata (`useMarkets`), on-chain
|
|
23
|
+
* fee rates (`useFeeForUser`), and the solver's static fees (`useSolverInfo`)
|
|
24
|
+
* are slow-moving and cached for minutes; the mark price rides the shared
|
|
25
|
+
* price stream. Previous data is kept while inputs move, so a mark-price tick
|
|
26
|
+
* updates the numbers in place.
|
|
27
|
+
*
|
|
28
|
+
* The holding time is stamped each time the query function runs, so a refetch
|
|
29
|
+
* after the position ages re-prices the decaying solver close fee; pass `now`
|
|
30
|
+
* for a deterministic preview. Narrow on `kind` to reach the lowcap-only legs
|
|
31
|
+
* (`closeSolverFee`, `closeSolverFeeRate`, `holdingSeconds`,
|
|
32
|
+
* `staticSolverFeeClose`).
|
|
33
|
+
*
|
|
34
|
+
* @example
|
|
35
|
+
* ```tsx
|
|
36
|
+
* const { data: fees } = useInstantCloseFees({
|
|
37
|
+
* subAccountAddress: partyA,
|
|
38
|
+
* market: { id: symbolId },
|
|
39
|
+
* quantity: quantityToClose,
|
|
40
|
+
* openedAt: position.createTimestamp,
|
|
41
|
+
* });
|
|
42
|
+
* // fees?.totalFee; fees?.kind === "enigma" && fees.closeSolverFee
|
|
43
|
+
* ```
|
|
44
|
+
*/
|
|
45
|
+
export declare function useInstantCloseFees(parameters: UseInstantCloseFeesParameters): UseInstantCloseFeesReturnType;
|
|
46
|
+
//# sourceMappingURL=use-instant-close-fees.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"use-instant-close-fees.d.ts","sourceRoot":"","sources":["../../src/instant-layer/use-instant-close-fees.ts"],"names":[],"mappings":"AAEA,OAAO,EAEL,KAAK,eAAe,EACpB,KAAK,0BAA0B,EAC/B,KAAK,6BAA6B,EACnC,MAAM,sBAAsB,CAAC;AAC9B,OAAO,EAAY,KAAK,cAAc,EAAE,MAAM,uBAAuB,CAAC;AAEtE,OAAO,KAAK,EAAE,kBAAkB,EAAE,MAAM,gCAAgC,CAAC;AAQzE;;;;GAIG;AACH,MAAM,MAAM,6BAA6B,GAAG,0BAA0B,GAAG,eAAe,CAAC;AAEzF,kDAAkD;AAClD,MAAM,MAAM,6BAA6B,GAAG,cAAc,CAAC,6BAA6B,EAAE,kBAAkB,CAAC,CAAC;AAE9G;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAgCG;AACH,wBAAgB,mBAAmB,CAAC,UAAU,EAAE,6BAA6B,GAAG,6BAA6B,CAqH5G"}
|