@stakekit/widget 0.0.274 → 0.0.276
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/bundle/Codec-DJMwdgB9.js +1 -0
- package/dist/bundle/{MaybeAsync-Ckzmgrqr.js → MaybeAsync-DQF5lNPa.js} +1 -1
- package/dist/bundle/{build-BMMgmQqw.js → build-CcaOMxqz.js} +1 -1
- package/dist/bundle/{build-BNPMa-vT.js → build-Dzd_3NK0.js} +1 -1
- package/dist/bundle/{cardano-connector-DKXfujiC.js → cardano-connector-Vvgvc_SR.js} +2 -2
- package/dist/bundle/cosmos-connector-meta-Ck8JH12i.js +1 -0
- package/dist/bundle/{createConnector-BrxGIkT7.js → createConnector-pbKKdb_k.js} +2 -2
- package/dist/bundle/{images-BMN9-6Cl.js → images-qNtx67Rl.js} +1 -1
- package/dist/bundle/index.bundle.css +1 -1
- package/dist/bundle/index.bundle.js +48 -48
- package/dist/bundle/{ledger-connector-DmvRDcyN.js → ledger-connector-C4GRsXg2.js} +2 -2
- package/dist/bundle/{ledger-live-connector-meta-DDQWxYWw.js → ledger-live-connector-meta-DbuxO2yY.js} +1 -1
- package/dist/bundle/{misc-BLlpZ6ih.js → misc-BtIN6y6p.js} +1 -1
- package/dist/bundle/safe-connector-Bwgtw9lc.js +1 -0
- package/dist/bundle/solana-connector-CaIkxhTb.js +1 -0
- package/dist/bundle/{substrate-connector-BKHfZY_J.js → substrate-connector-BDRBscm1.js} +1 -1
- package/dist/bundle/{ton-connector-BRAeK9Od.js → ton-connector-CnNKzHtr.js} +2 -2
- package/dist/bundle/{transaction-ixhTmhET.js → transaction-DB7k-q8u.js} +1 -1
- package/dist/bundle/{tron-connector-Cr2j2DtV.js → tron-connector-C5KUqegL.js} +2 -2
- package/dist/bundle/tx-DygTArs0.js +1 -0
- package/dist/bundle/{wallet-manager-B2J-l9Hd.js → wallet-manager-C9fisl4Y.js} +2 -2
- package/dist/package/{Codec-Byh8iois.js → Codec-Bae2iyFH.js} +1 -1
- package/dist/package/{MaybeAsync-BZLAl2bE.js → MaybeAsync-DXWsPM9n.js} +1 -1
- package/dist/package/{build-jVm_Imk7.js → build-CYy6v80s.js} +1 -1
- package/dist/package/{build-BxgetfN5.js → build-GgZW6uL5.js} +2 -2
- package/dist/package/{cardano-connector-DPlMH8wa.js → cardano-connector-CchOT0g5.js} +3 -3
- package/dist/package/{cosmos-connector-meta-MR5we2DB.js → cosmos-connector-meta-Dtfahon-.js} +2 -2
- package/dist/package/{createConnector-c-2Ie22W.js → createConnector-D-p8-Ebj.js} +1 -10
- package/dist/package/{images-0ZMBvxwm.js → images-B0-tGuTw.js} +1 -1
- package/dist/package/index.package.css +70 -67
- package/dist/package/index.package.js +3972 -4165
- package/dist/package/{ledger-connector-Cf6yV8eL.js → ledger-connector-BhbNzz5z.js} +5 -5
- package/dist/package/{ledger-live-connector-meta-CIDYYFrg.js → ledger-live-connector-meta-C4-iTYoS.js} +3 -3
- package/dist/package/{misc-Erb32S3W.js → misc-DFHb1ynZ.js} +1 -1
- package/dist/package/{safe-connector-B8DuxkSp.js → safe-connector-CAgz56zm.js} +2 -2
- package/dist/package/{solana-connector-BgSU_Au0.js → solana-connector-C4-3zQ0W.js} +2 -2
- package/dist/package/{substrate-connector-CfrmkJYW.js → substrate-connector-WYvMgtq6.js} +2 -2
- package/dist/package/{ton-connector-tEtLRW28.js → ton-connector-DGVU07fk.js} +4 -4
- package/dist/package/{transaction-BaxD0vuC.js → transaction-BhfOz9qC.js} +2 -2
- package/dist/package/{tron-connector-DGBu9r65.js → tron-connector-Bx8ow-to.js} +4 -4
- package/dist/package/tx-DQaheDj7.js +3 -0
- package/dist/package/{wallet-manager-D5jYaNnr.js → wallet-manager-Bf0VaUFt.js} +10 -10
- package/dist/types/components/atoms/token-icon/network-icon-image/index.d.ts +2 -1
- package/dist/types/components/molecules/estimated-reward-amounts/index.d.ts +6 -0
- package/dist/types/components/molecules/select-opportunity-list-item/index.d.ts +7 -5
- package/dist/types/domain/types/stake.d.ts +3 -3
- package/dist/types/domain/types/yields.d.ts +13 -18
- package/dist/types/hooks/api/use-dashboard-yield-catalog.d.ts +2 -0
- package/dist/types/hooks/api/use-multi-yields.d.ts +6 -3
- package/dist/types/hooks/api/use-yield-opportunity/get-yield-opportunity.d.ts +5 -1
- package/dist/types/hooks/api/use-yield-providers.d.ts +13 -0
- package/dist/types/hooks/api/use-yield-summaries.d.ts +10 -7
- package/dist/types/pages/complete/hooks/use-complete.hook.d.ts +2 -0
- package/dist/types/pages/complete/state/index.d.ts +2 -0
- package/dist/types/pages/components/page-cta.d.ts +11 -0
- package/dist/types/pages/details/earn-page/components/select-token-section/select-token-list-item.d.ts +1 -5
- package/dist/types/pages/details/earn-page/components/select-token-section/styles.css.d.ts +0 -2
- package/dist/types/pages/details/earn-page/components/select-yield-section/styles.css.d.ts +1 -0
- package/dist/types/pages/details/earn-page/state/types.d.ts +8 -9
- package/dist/types/pages/details/earn-page/state/use-get-init-yield.d.ts +3 -1
- package/dist/types/pages/details/earn-page/state/use-init-yield.d.ts +3 -1
- package/dist/types/pages/details/earn-page/types.d.ts +3 -3
- package/dist/types/pages/position-details/hooks/use-unstake-machine.d.ts +7 -118
- package/dist/types/pages/review/hooks/use-action-review.hook.d.ts +2 -0
- package/dist/types/pages/review/hooks/use-pending-review.hook.d.ts +2 -0
- package/dist/types/pages/review/hooks/use-stake-review.hook.d.ts +43 -1
- package/dist/types/pages/review/hooks/use-unstake-review.hook.d.ts +2 -0
- package/dist/types/pages/review/pages/common-page/common.page.d.ts +7 -1
- package/dist/types/pages/review/pages/common-page/components/review-top-section.d.ts +5 -1
- package/dist/types/pages/steps/hooks/use-steps.hook.d.ts +2 -0
- package/dist/types/pages-dashboard/overview/earn-details/earn-details-formatters.d.ts +2 -0
- package/dist/types/pages-dashboard/position-details/components/position-details-stake-actions.d.ts +0 -4
- package/dist/types/providers/api/api-client-provider.d.ts +6 -22
- package/dist/types/providers/api/api-client.d.ts +6 -22
- package/dist/types/providers/ethereum/config.d.ts +4 -3
- package/dist/types/providers/settings/types.d.ts +1 -0
- package/dist/types/providers/wagmi/index.d.ts +1 -0
- package/dist/types/translation/resources.d.ts +4 -0
- package/dist/types/utils/formatters.d.ts +1 -0
- package/dist/types/utils/index.d.ts +0 -1
- package/dist/website/assets/Codec-C8kGgbSv.js +1 -0
- package/dist/website/assets/{basic-CibIan8y.js → basic-CpcEs1GD.js} +1 -1
- package/dist/website/assets/{basic-BVJnMIHl.js → basic-DU5w7kdv.js} +1 -1
- package/dist/website/assets/{browser--EMMYaan.js → browser-DvOBRbll.js} +1 -1
- package/dist/website/assets/{build-DFEPAT8y.js → build-Cr-Kp_EZ.js} +1 -1
- package/dist/website/assets/{build-BPw0SHWb.js → build-rt6xIlo_.js} +1 -1
- package/dist/website/assets/{cardano-connector-CbHZBb34.js → cardano-connector-Cmbkas8k.js} +2 -2
- package/dist/website/assets/{core-BSLy_t4A.js → core-BCBOJeDN.js} +2 -2
- package/dist/website/assets/{createConnector-BcHSC56W.js → createConnector-mvBxgXDZ.js} +2 -2
- package/dist/website/assets/{dist-DAbkzFAO.js → dist-D00tXgFF.js} +1 -1
- package/dist/website/assets/{dist-BRCQU1Li.js → dist-cxjMJHcC.js} +1 -1
- package/dist/website/assets/en_US-IFPOGBSL-CZkuvGib.js +1 -0
- package/dist/website/assets/{esm-FztE-O2S.js → esm-DwAVGOvO.js} +1 -1
- package/dist/website/assets/{exports-DiWzDOxG.js → exports-Bd3_9cI2.js} +1 -1
- package/dist/website/assets/index-B7bJTB96.js +2044 -0
- package/dist/website/assets/{index-E_6jknHw.css → index-Cm1198kl.css} +1 -1
- package/dist/website/assets/{index.es-D3Xa7Qme.js → index.es-pxgKNF2Q.js} +2 -2
- package/dist/website/assets/{ledger-connector-6wqonZoy.js → ledger-connector-Dl0ewoRv.js} +2 -2
- package/dist/website/assets/{receive-BN_rE1dd.js → receive-Cb9X0-X3.js} +1 -1
- package/dist/website/assets/{registry-DLj0P6dj.js → registry-qGhX95wF.js} +1 -1
- package/dist/website/assets/safe-connector-fpbcUPyE.js +1 -0
- package/dist/website/assets/{socials-C3M2JNCz.js → socials-IzpjXHEF.js} +1 -1
- package/dist/website/assets/solana-connector-DMwmOYcE.js +1 -0
- package/dist/website/assets/{substrate-connector-CCxDFYG6.js → substrate-connector-BjmH8Kfk.js} +1 -1
- package/dist/website/assets/{ton-connector-DlVKNF8w.js → ton-connector-CDdILKhA.js} +2 -2
- package/dist/website/assets/{tron-connector-C6xS9wMC.js → tron-connector-CwTP3MOd.js} +3 -3
- package/dist/website/assets/tx-B1U8yUTO.js +1 -0
- package/dist/website/assets/{wallet-manager-BxPcB4lR.js → wallet-manager-cSwSAC9E.js} +4 -4
- package/dist/website/assets/{wui-qr-code-CNh2d2fT.js → wui-qr-code-CulBm8yY.js} +1 -1
- package/dist/website/index.html +4 -4
- package/package.json +1 -1
- package/dist/bundle/Codec-FOvoaP2K.js +0 -1
- package/dist/bundle/cosmos-connector-meta-DO5i3lCd.js +0 -1
- package/dist/bundle/safe-connector-BgDwaGsX.js +0 -1
- package/dist/bundle/solana-connector-h5iUra8H.js +0 -1
- package/dist/bundle/tx-C-_PyHR9.js +0 -1
- package/dist/package/tx-DpCUKNN4.js +0 -3
- package/dist/types/hooks/api/use-token-list-yields.d.ts +0 -21
- package/dist/types/pages/components/footer-outlet/context.d.ts +0 -20
- package/dist/types/pages/components/footer-outlet/index.d.ts +0 -1
- package/dist/types/pages/components/footer-outlet/styles.css.d.ts +0 -1
- package/dist/types/pages-dashboard/common/components/footer-outlet/index.d.ts +0 -1
- package/dist/website/assets/Codec-D4K5RIsS.js +0 -1
- package/dist/website/assets/en_US-IFPOGBSL-BzV0u3lE.js +0 -1
- package/dist/website/assets/index-BIOEiLJw.js +0 -2044
- package/dist/website/assets/safe-connector-NQlNJxmf.js +0 -1
- package/dist/website/assets/solana-connector-hzwYOzto.js +0 -1
- package/dist/website/assets/tx-CXZ9mGxZ.js +0 -1
|
@@ -1,13 +1,13 @@
|
|
|
1
1
|
"use client";
|
|
2
2
|
import { t as __commonJSMin } from "./chunk-DwwZaK3i.js";
|
|
3
|
-
import {
|
|
4
|
-
import { P as List, a as isEvmChain, g as map, t as configMeta, w as skNormalizeChainId } from "./ledger-live-connector-meta-
|
|
5
|
-
import { n as EitherAsync } from "./MaybeAsync-
|
|
6
|
-
import { t as images } from "./images-
|
|
3
|
+
import { D as BigNumber$1, G as Maybe, H as Either, S as isLedgerDappBrowserProvider, U as left, W as right, n as BehaviorSubject, t as createConnector, w as typeSafeObjectEntries } from "./createConnector-D-p8-Ebj.js";
|
|
4
|
+
import { P as List, a as isEvmChain, g as map, t as configMeta, w as skNormalizeChainId } from "./ledger-live-connector-meta-C4-iTYoS.js";
|
|
5
|
+
import { n as EitherAsync } from "./MaybeAsync-DXWsPM9n.js";
|
|
6
|
+
import { t as images } from "./images-B0-tGuTw.js";
|
|
7
7
|
import { i as init_dist, t as Buffer } from "./dist-BI2Nn6FN.js";
|
|
8
8
|
import { t as hexToBytes } from "./toBytes-5OHWnbJl.js";
|
|
9
9
|
import { a as SubstrateNetworks, n as EvmNetworks, r as MiscNetworks, t as CosmosNetworks } from "./networks-C4wBuQAR.js";
|
|
10
|
-
import { a as unsignedTonTransactionCodec, n as substratePayloadCodec, r as unsignedEVMTransactionCodec, s as unsignedTronTransactionCodec } from "./transaction-
|
|
10
|
+
import { a as unsignedTonTransactionCodec, n as substratePayloadCodec, r as unsignedEVMTransactionCodec, s as unsignedTronTransactionCodec } from "./transaction-BhfOz9qC.js";
|
|
11
11
|
import { c as serializeError, s as deserializeError, t as Transport } from "./Transport-B7iFMzn6.js";
|
|
12
12
|
import { t as v4 } from "./v4-YIlmluLc.js";
|
|
13
13
|
import { n as require_dist$1, t as require_dist$2 } from "./dist-BlAqJor4.js";
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
"use client";
|
|
2
|
-
import {
|
|
3
|
-
import { d as orderToNumber } from "./Codec-
|
|
2
|
+
import { D as BigNumber, G as Maybe, K as just, N as __extends, U as left, W as right, f as isFunction, q as nothing, s as Subscriber, y as getNetworkLogo, z as init_tslib_es6 } from "./createConnector-D-p8-Ebj.js";
|
|
3
|
+
import { d as orderToNumber } from "./Codec-Bae2iyFH.js";
|
|
4
4
|
import { S as InvalidAddressError, b as isAddress, h as slice, m as concatHex } from "./getAbiItem-BVX2yDB3.js";
|
|
5
5
|
import { a as bytesToHex, c as toHex, f as hexToNumber, m as trim, o as numberToHex, u as hexToBigInt, x as size } from "./toBytes-5OHWnbJl.js";
|
|
6
6
|
import { t as BaseError } from "./base-BTwN_DlC.js";
|
|
@@ -8,7 +8,7 @@ import { P as InvalidChainIdError, _ as InvalidStorageKeySizeError, h as Invalid
|
|
|
8
8
|
import { n as FeeCapTooHighError, u as TipAboveFeeCapError } from "./node-Sc4f3aSR.js";
|
|
9
9
|
import { b as toRlp, c as getTransactionType, d as InvalidVersionedHashSizeError, f as InvalidVersionedHashVersionError, g as defineBlock, h as blobsToCommitments, l as toBlobSidecars, m as blobsToProofs, o as defineChain, p as commitmentsToVersionedHashes, r as defineTransactionReceipt, t as AccountNotFoundError, u as EmptyBlobError, v as defineTransaction, y as formatTransaction } from "./account-KyBwHgfH.js";
|
|
10
10
|
import { a as SubstrateNetworks, n as EvmNetworks, r as MiscNetworks, t as CosmosNetworks } from "./networks-C4wBuQAR.js";
|
|
11
|
-
import { a as supportedMiscChainsSet } from "./misc-
|
|
11
|
+
import { a as supportedMiscChainsSet } from "./misc-DFHb1ynZ.js";
|
|
12
12
|
//#region ../../node_modules/.pnpm/purify-ts@2.1.4_patch_hash=5a25e93220157c14f071521854d75c4da38ec0e15fad1989f51e87be19c2fd63/node_modules/purify-ts/esm/Tuple.js
|
|
13
13
|
var TupleImpl = class {
|
|
14
14
|
constructor(first, second) {
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
"use client";
|
|
2
|
-
import {
|
|
2
|
+
import { b as getTokenLogo } from "./createConnector-D-p8-Ebj.js";
|
|
3
3
|
import { r as MiscNetworks } from "./networks-C4wBuQAR.js";
|
|
4
4
|
//#region src/domain/types/chains/misc.ts
|
|
5
5
|
var supportedMiscChains = [
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
"use client";
|
|
2
|
-
import {
|
|
3
|
-
import { n as EitherAsync } from "./MaybeAsync-
|
|
2
|
+
import { G as Maybe, n as BehaviorSubject, t as createConnector, x as isIframe } from "./createConnector-D-p8-Ebj.js";
|
|
3
|
+
import { n as EitherAsync } from "./MaybeAsync-DXWsPM9n.js";
|
|
4
4
|
import { y as getAddress } from "./getAbiItem-BVX2yDB3.js";
|
|
5
5
|
import { t as withTimeout } from "./withTimeout-C43RlPy3.js";
|
|
6
6
|
import { r as ProviderNotFoundError, t as configMeta } from "./safe-connector-meta-Ddl09ZBC.js";
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
"use client";
|
|
2
|
-
import {
|
|
2
|
+
import { G as Maybe, n as BehaviorSubject, t as createConnector, y as getNetworkLogo } from "./createConnector-D-p8-Ebj.js";
|
|
3
3
|
import { i as init_dist, t as Buffer } from "./dist-BI2Nn6FN.js";
|
|
4
4
|
import { r as MiscNetworks } from "./networks-C4wBuQAR.js";
|
|
5
|
-
import { i as solana } from "./misc-
|
|
5
|
+
import { i as solana } from "./misc-DFHb1ynZ.js";
|
|
6
6
|
import { i as WalletConnectWalletAdapter, l as Transaction, n as getConfigMeta, p as init_index_browser_esm, t as porto_default, u as VersionedTransaction } from "./porto-Gmzp7rdP.js";
|
|
7
7
|
//#region src/providers/misc/solana-connector.ts
|
|
8
8
|
init_dist();
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
"use client";
|
|
2
|
-
import { G as
|
|
3
|
-
import { n as EitherAsync } from "./MaybeAsync-
|
|
2
|
+
import { G as Maybe, H as Either, V as config, W as right, n as BehaviorSubject, t as createConnector, y as getNetworkLogo } from "./createConnector-D-p8-Ebj.js";
|
|
3
|
+
import { n as EitherAsync } from "./MaybeAsync-DXWsPM9n.js";
|
|
4
4
|
import { i as init_dist } from "./dist-BI2Nn6FN.js";
|
|
5
5
|
import { h as init_utils, l as concatBytes, m as hexToBytes, s as bytesToHex } from "./utils-CZZflqSo.js";
|
|
6
6
|
import { n as import_eventemitter3 } from "./eventemitter3-kaa1hYrC.js";
|
|
@@ -1,12 +1,12 @@
|
|
|
1
1
|
"use client";
|
|
2
2
|
import { s as __toESM, t as __commonJSMin } from "./chunk-DwwZaK3i.js";
|
|
3
3
|
import { n as process$1, t as init_dist } from "./dist-BeCWYci1.js";
|
|
4
|
-
import {
|
|
5
|
-
import { n as EitherAsync } from "./MaybeAsync-
|
|
4
|
+
import { H as Either, n as BehaviorSubject, t as createConnector, y as getNetworkLogo } from "./createConnector-D-p8-Ebj.js";
|
|
5
|
+
import { n as EitherAsync } from "./MaybeAsync-DXWsPM9n.js";
|
|
6
6
|
import { i as init_dist$1, t as Buffer } from "./dist-BI2Nn6FN.js";
|
|
7
7
|
import { r as MiscNetworks } from "./networks-C4wBuQAR.js";
|
|
8
|
-
import { o as ton } from "./misc-
|
|
9
|
-
import { o as unsignedTonTransactionTonConnectCodec } from "./transaction-
|
|
8
|
+
import { o as ton } from "./misc-DFHb1ynZ.js";
|
|
9
|
+
import { o as unsignedTonTransactionTonConnectCodec } from "./transaction-BhfOz9qC.js";
|
|
10
10
|
import { n as configMeta, t as require_ua_parser } from "./ua-parser-BdHJ6jgK.js";
|
|
11
11
|
import { t as require_cjs } from "./cjs-DZfpolVf.js";
|
|
12
12
|
import { r as require_nacl_fast, t as require_dist } from "./dist-BlAqJor4.js";
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
"use client";
|
|
2
|
-
import {
|
|
3
|
-
import { a as oneOf, c as string, i as number, l as unknown, n as array, o as optional, r as boolean, s as record, t as Codec } from "./Codec-
|
|
2
|
+
import { U as left, W as right } from "./createConnector-D-p8-Ebj.js";
|
|
3
|
+
import { a as oneOf, c as string, i as number, l as unknown, n as array, o as optional, r as boolean, s as record, t as Codec } from "./Codec-Bae2iyFH.js";
|
|
4
4
|
import { o as numberToHex } from "./toBytes-5OHWnbJl.js";
|
|
5
5
|
//#region src/domain/types/transaction.ts
|
|
6
6
|
var bigintCodec = Codec.custom({
|
|
@@ -1,15 +1,15 @@
|
|
|
1
1
|
"use client";
|
|
2
2
|
import { r as __exportAll, s as __toESM, t as __commonJSMin } from "./chunk-DwwZaK3i.js";
|
|
3
3
|
import { n as process$1, t as init_dist } from "./dist-BeCWYci1.js";
|
|
4
|
-
import {
|
|
5
|
-
import { n as EitherAsync } from "./MaybeAsync-
|
|
4
|
+
import { G as Maybe, V as config, b as getTokenLogo, n as BehaviorSubject, t as createConnector, y as getNetworkLogo } from "./createConnector-D-p8-Ebj.js";
|
|
5
|
+
import { n as EitherAsync } from "./MaybeAsync-DXWsPM9n.js";
|
|
6
6
|
import { n as init_dist$1, t as global } from "./dist-BuxloV2e.js";
|
|
7
|
-
import { t as images } from "./images-
|
|
7
|
+
import { t as images } from "./images-B0-tGuTw.js";
|
|
8
8
|
import { i as init_dist$2, n as Buffer$1, t as Buffer } from "./dist-BI2Nn6FN.js";
|
|
9
9
|
import { c as toHex$1 } from "./toBytes-5OHWnbJl.js";
|
|
10
10
|
import { t as eventemitter3_default } from "./eventemitter3-kaa1hYrC.js";
|
|
11
11
|
import { r as MiscNetworks } from "./networks-C4wBuQAR.js";
|
|
12
|
-
import { s as tron } from "./misc-
|
|
12
|
+
import { s as tron } from "./misc-DFHb1ynZ.js";
|
|
13
13
|
import { n as esm_default } from "./index.es-YtziYxuZ.js";
|
|
14
14
|
import { a as TransportError, i as DisconnectedDeviceDuringOperation, n as log, o as TransportOpenUserCancelled, r as DisconnectedDevice, t as Transport } from "./Transport-B7iFMzn6.js";
|
|
15
15
|
import { i as k$2, t as A$3 } from "./index.es-BgXiw4kQ.js";
|
|
@@ -1,11 +1,11 @@
|
|
|
1
1
|
"use client";
|
|
2
2
|
import { a as __require, n as __esmMin, o as __toCommonJS, r as __exportAll, s as __toESM, t as __commonJSMin } from "./chunk-DwwZaK3i.js";
|
|
3
3
|
import { n as process$1, t as init_dist } from "./dist-BeCWYci1.js";
|
|
4
|
-
import {
|
|
5
|
-
import { n as EitherAsync } from "./MaybeAsync-
|
|
4
|
+
import { E as waitForMs, K as just, V as config, n as BehaviorSubject, t as createConnector, y as getNetworkLogo } from "./createConnector-D-p8-Ebj.js";
|
|
5
|
+
import { n as EitherAsync } from "./MaybeAsync-DXWsPM9n.js";
|
|
6
6
|
import { n as init_dist$1, t as global } from "./dist-BuxloV2e.js";
|
|
7
|
-
import { t as images } from "./images-
|
|
8
|
-
import { a as setStorageItem, i as getStorageItem, t as configMeta } from "./cosmos-connector-meta-
|
|
7
|
+
import { t as images } from "./images-B0-tGuTw.js";
|
|
8
|
+
import { a as setStorageItem, i as getStorageItem, t as configMeta } from "./cosmos-connector-meta-Dtfahon-.js";
|
|
9
9
|
import { i as init_dist$2, r as dist_exports, t as Buffer } from "./dist-BI2Nn6FN.js";
|
|
10
10
|
import { t as CosmosNetworks } from "./networks-C4wBuQAR.js";
|
|
11
11
|
import { i as init_eventemitter3, n as eventemitter3_default, t as require_bs58 } from "./bs58-CB1H6C75.js";
|
|
@@ -9897,12 +9897,12 @@ var ChainWalletBase = class extends WalletBase {
|
|
|
9897
9897
|
};
|
|
9898
9898
|
getStargateClient = async () => {
|
|
9899
9899
|
const rpcEndpoint = await this.getRpcEndpoint();
|
|
9900
|
-
const { StargateClient } = await import("./build-
|
|
9900
|
+
const { StargateClient } = await import("./build-CYy6v80s.js").then((n) => /* @__PURE__ */ __toESM(n.t()));
|
|
9901
9901
|
return StargateClient.connect(rpcEndpoint, this.stargateOptions);
|
|
9902
9902
|
};
|
|
9903
9903
|
getCosmWasmClient = async () => {
|
|
9904
9904
|
const rpcEndpoint = await this.getRpcEndpoint();
|
|
9905
|
-
const { CosmWasmClient } = await import("./build-
|
|
9905
|
+
const { CosmWasmClient } = await import("./build-GgZW6uL5.js").then((m) => /* @__PURE__ */ __toESM(m.default));
|
|
9906
9906
|
return CosmWasmClient.connect(rpcEndpoint);
|
|
9907
9907
|
};
|
|
9908
9908
|
getNameService = async () => {
|
|
@@ -9920,13 +9920,13 @@ var ChainWalletBase = class extends WalletBase {
|
|
|
9920
9920
|
getSigningStargateClient = async () => {
|
|
9921
9921
|
const rpcEndpoint = await this.getRpcEndpoint();
|
|
9922
9922
|
if (!this.offlineSigner) await this.initOfflineSigner();
|
|
9923
|
-
const { SigningStargateClient } = await import("./build-
|
|
9923
|
+
const { SigningStargateClient } = await import("./build-CYy6v80s.js").then((n) => /* @__PURE__ */ __toESM(n.t()));
|
|
9924
9924
|
return SigningStargateClient.connectWithSigner(rpcEndpoint, this.offlineSigner, this.signingStargateOptions);
|
|
9925
9925
|
};
|
|
9926
9926
|
getSigningCosmWasmClient = async () => {
|
|
9927
9927
|
const rpcEndpoint = await this.getRpcEndpoint();
|
|
9928
9928
|
if (!this.offlineSigner) await this.initOfflineSigner();
|
|
9929
|
-
const { SigningCosmWasmClient } = await import("./build-
|
|
9929
|
+
const { SigningCosmWasmClient } = await import("./build-GgZW6uL5.js").then((m) => /* @__PURE__ */ __toESM(m.default));
|
|
9930
9930
|
return SigningCosmWasmClient.connectWithSigner(rpcEndpoint, this.offlineSigner, this.signingCosmwasmOptions);
|
|
9931
9931
|
};
|
|
9932
9932
|
getSigningClient = async (type) => {
|
|
@@ -9952,7 +9952,7 @@ var ChainWalletBase = class extends WalletBase {
|
|
|
9952
9952
|
}
|
|
9953
9953
|
if (!gasPrice) throw new Error("Gas price must be set in the client options when auto gas is used.");
|
|
9954
9954
|
const gasEstimation = await (await this.getSigningClient(type)).simulate(this.address, messages, memo);
|
|
9955
|
-
const { calculateFee } = await import("./build-
|
|
9955
|
+
const { calculateFee } = await import("./build-CYy6v80s.js").then((n) => /* @__PURE__ */ __toESM(n.t()));
|
|
9956
9956
|
return calculateFee(Math.round(gasEstimation * (multiplier || 1.4)), gasPrice);
|
|
9957
9957
|
};
|
|
9958
9958
|
sign = async (messages, fee, memo, type) => {
|
|
@@ -9965,7 +9965,7 @@ var ChainWalletBase = class extends WalletBase {
|
|
|
9965
9965
|
};
|
|
9966
9966
|
broadcast = async (signedMessages, type) => {
|
|
9967
9967
|
const client = await this.getSigningClient(type);
|
|
9968
|
-
const { TxRaw } = await import("./tx-
|
|
9968
|
+
const { TxRaw } = await import("./tx-DQaheDj7.js").then((m) => /* @__PURE__ */ __toESM(m.default));
|
|
9969
9969
|
const txBytes = TxRaw.encode(signedMessages).finish();
|
|
9970
9970
|
let timeoutMs, pollIntervalMs;
|
|
9971
9971
|
switch (type) {
|
|
@@ -1,7 +1,8 @@
|
|
|
1
1
|
import type { Atoms } from "../../../../styles/theme/atoms.css";
|
|
2
2
|
type NetworkLogoImageProps = {
|
|
3
3
|
networkLogoUri: string;
|
|
4
|
+
networkName?: string;
|
|
4
5
|
tokenNetworkLogoHw?: Atoms["hw"];
|
|
5
6
|
};
|
|
6
|
-
export declare const NetworkLogoImage: ({ networkLogoUri, tokenNetworkLogoHw, }: NetworkLogoImageProps) => import("react/jsx-runtime").JSX.Element;
|
|
7
|
+
export declare const NetworkLogoImage: ({ networkLogoUri, networkName, tokenNetworkLogoHw, }: NetworkLogoImageProps) => import("react/jsx-runtime").JSX.Element;
|
|
7
8
|
export {};
|
|
@@ -1,7 +1,9 @@
|
|
|
1
|
-
import type {
|
|
2
|
-
|
|
3
|
-
item:
|
|
4
|
-
onYieldSelect: (item:
|
|
1
|
+
import type { YieldBase } from "../../../domain/types/yields";
|
|
2
|
+
type SelectOpportunityListItemProps<T extends YieldBase> = {
|
|
3
|
+
item: T;
|
|
4
|
+
onYieldSelect: (item: T) => void;
|
|
5
5
|
testId?: string;
|
|
6
6
|
selected?: boolean;
|
|
7
|
-
}
|
|
7
|
+
};
|
|
8
|
+
export declare const SelectOpportunityListItem: <T extends YieldBase>({ item, onYieldSelect, testId, selected, }: SelectOpportunityListItemProps<T>) => import("react/jsx-runtime").JSX.Element;
|
|
9
|
+
export {};
|
|
@@ -7,7 +7,7 @@ import type { InitParams } from "./init-params";
|
|
|
7
7
|
import type { PositionsData } from "./positions";
|
|
8
8
|
import type { TokenBalanceScanResponseDto } from "./token-balance";
|
|
9
9
|
import type { TokenString } from "./tokens";
|
|
10
|
-
import { type Yield } from "./yields";
|
|
10
|
+
import { type Yield, type YieldBase } from "./yields";
|
|
11
11
|
export type PreferredTokenYieldsPerNetwork = {
|
|
12
12
|
[Key in SupportedSKChains]?: Record<TokenString, "*" | (Yield["id"] & {})>;
|
|
13
13
|
};
|
|
@@ -20,7 +20,7 @@ export declare const getInitialToken: (args: {
|
|
|
20
20
|
}) => import("purify-ts/Maybe").Maybe<import("../../generated/api/legacy").TokenDto>;
|
|
21
21
|
export declare const canBeInitialYield: (args: {
|
|
22
22
|
initQueryParams: Maybe<InitParams>;
|
|
23
|
-
yieldDto:
|
|
23
|
+
yieldDto: YieldBase;
|
|
24
24
|
tokenBalanceAmount: BigNumber;
|
|
25
25
|
positionsData: PositionsData;
|
|
26
26
|
}) => boolean;
|
|
@@ -33,5 +33,5 @@ export declare const isForceMaxAmount: (args: {
|
|
|
33
33
|
maximum?: number | null;
|
|
34
34
|
} | null | undefined) => boolean;
|
|
35
35
|
export declare const isNetworkWithEnterMinBasedOnPosition: (network: Networks) => boolean;
|
|
36
|
-
export declare const getMinStakeAmount: (yieldDto:
|
|
36
|
+
export declare const getMinStakeAmount: (yieldDto: YieldBase, positionsData: PositionsData) => BigNumber;
|
|
37
37
|
export declare const getMinUnstakeAmount: (yieldDto: Yield, pricePerShare: string | null) => BigNumber;
|
|
@@ -1,12 +1,11 @@
|
|
|
1
1
|
import type { TFunction } from "i18next";
|
|
2
|
-
import type { YieldDto as OldYieldDto } from "../../generated/api/legacy";
|
|
3
2
|
import type { YieldType as ApiYieldType, ArgumentFieldDto, ProviderDto, ValidatorDto, YieldDto as YieldApiYieldDto, YieldRiskEntryDto } from "../../generated/api/yield";
|
|
4
3
|
import type { SupportedSKChains } from "./chains";
|
|
4
|
+
export type YieldProviderDetails = ProviderDto;
|
|
5
5
|
export type Yield = YieldApiYieldDto & {
|
|
6
|
-
__fallback__: OldYieldDto;
|
|
7
6
|
provider?: YieldProviderDetails;
|
|
8
7
|
};
|
|
9
|
-
export type
|
|
8
|
+
export type YieldBase = Yield;
|
|
10
9
|
type YieldRiskRatingTone = "positive" | "warning" | "danger" | "neutral";
|
|
11
10
|
type KnownYieldRiskRatingSource = YieldRiskEntryDto["source"];
|
|
12
11
|
type YieldRiskRatingSource = KnownYieldRiskRatingSource | (string & {});
|
|
@@ -44,19 +43,18 @@ export type ValidatorsConfig = Map<SupportedSKChains | "*", {
|
|
|
44
43
|
preferredOnly: boolean;
|
|
45
44
|
}>;
|
|
46
45
|
export type DashboardYieldCategory = "stake" | "defi" | "rwa";
|
|
47
|
-
export declare const dashboardYieldCategories: readonly ["
|
|
46
|
+
export declare const dashboardYieldCategories: readonly ["rwa", "defi", "stake"];
|
|
48
47
|
export declare const getApiYieldTypesForDashboardCategory: (category: DashboardYieldCategory) => ApiYieldType[];
|
|
49
|
-
export declare const
|
|
50
|
-
export declare const getDashboardYieldCategory: (yieldDto: Yield) => DashboardYieldCategory | null;
|
|
48
|
+
export declare const getDashboardYieldCategory: (yieldDto: YieldBase) => DashboardYieldCategory | null;
|
|
51
49
|
export declare const filterValidators: ({ validatorsConfig, validators, network, yieldId, }: {
|
|
52
50
|
validatorsConfig: ValidatorsConfig;
|
|
53
51
|
validators: ValidatorDto[];
|
|
54
52
|
network: Yield["token"]["network"];
|
|
55
53
|
yieldId?: Yield["id"];
|
|
56
54
|
}) => ValidatorDto[];
|
|
57
|
-
export declare const getYieldActionArg: (yieldDto:
|
|
58
|
-
export declare const isYieldActionArgRequired: (yieldDto:
|
|
59
|
-
export declare const getYieldRewardTokens: (yieldDto:
|
|
55
|
+
export declare const getYieldActionArg: (yieldDto: YieldBase, type: YieldActionType, name: YieldArgumentName) => YieldArgumentConfig | null;
|
|
56
|
+
export declare const isYieldActionArgRequired: (yieldDto: YieldBase, type: YieldActionType, name: YieldArgumentName) => boolean;
|
|
57
|
+
export declare const getYieldRewardTokens: (yieldDto: YieldBase) => {
|
|
60
58
|
readonly symbol: string;
|
|
61
59
|
readonly name: string;
|
|
62
60
|
readonly decimals: number;
|
|
@@ -75,15 +73,13 @@ export declare const getYieldCooldownPeriod: (yieldDto: Yield) => {
|
|
|
75
73
|
export declare const getYieldWarmupPeriod: (yieldDto: Yield) => {
|
|
76
74
|
days: number;
|
|
77
75
|
} | undefined;
|
|
78
|
-
export declare const getYieldCommission: (yieldDto: Yield) => readonly import("../../generated/api/legacy").YieldCommissionDto[] | undefined;
|
|
79
76
|
export declare const getYieldTvlUsd: (yieldDto: Yield) => string | null;
|
|
80
77
|
export declare const getYieldFeePercent: (yieldDto: Yield) => number | null;
|
|
81
78
|
export declare const getYieldLockupPeriod: (yieldDto: Yield) => {
|
|
82
79
|
days: number;
|
|
83
80
|
} | undefined;
|
|
84
|
-
export declare const
|
|
85
|
-
export declare const
|
|
86
|
-
export declare const getYieldOutputToken: (yieldDto: Yield) => import("purify-ts/Maybe").Maybe<{
|
|
81
|
+
export declare const getExtendedYieldType: (yieldDto: YieldBase) => ExtendedYieldType;
|
|
82
|
+
export declare const getYieldOutputToken: (yieldDto: YieldBase) => import("purify-ts/Maybe").Maybe<{
|
|
87
83
|
readonly symbol: string;
|
|
88
84
|
readonly name: string;
|
|
89
85
|
readonly decimals: number;
|
|
@@ -95,11 +91,10 @@ export declare const getYieldOutputToken: (yieldDto: Yield) => import("purify-ts
|
|
|
95
91
|
}>;
|
|
96
92
|
export declare const isUnstakeYieldType: (yieldType: ExtendedYieldType) => yieldType is "native_staking" | "staking" | "restaking" | "pooled_staking";
|
|
97
93
|
export declare const isDepositYieldType: (yieldType: ExtendedYieldType) => yieldType is "vault" | "lending" | "fixed_yield" | "real_world_asset" | "concentrated_liquidity_pool" | "liquidity_pool";
|
|
98
|
-
export declare const getYieldTypeLabels: (yieldDto:
|
|
99
|
-
export declare const getYieldTypesSortRank: (yieldDto:
|
|
100
|
-
export declare const isYieldWithProviderOptions: (yieldDto:
|
|
101
|
-
export declare const getYieldProviderYieldIds: (yieldDto:
|
|
102
|
-
export declare const isYieldIntegrationAggregator: (yieldDto: Yield) => boolean;
|
|
94
|
+
export declare const getYieldTypeLabels: (yieldDto: YieldBase, t: TFunction) => YieldTypeLabelsMap[keyof YieldTypeLabelsMap];
|
|
95
|
+
export declare const getYieldTypesSortRank: (yieldDto: YieldBase) => number;
|
|
96
|
+
export declare const isYieldWithProviderOptions: (yieldDto: YieldBase) => boolean;
|
|
97
|
+
export declare const getYieldProviderYieldIds: (yieldDto: YieldBase) => string[];
|
|
103
98
|
export declare const isYieldValidatorSelectionRequired: (yieldDto: Yield) => boolean;
|
|
104
99
|
export declare const isEthenaUsdeStaking: (yieldId: string) => yieldId is "ethena-usde-staking";
|
|
105
100
|
export declare const isBittensorStaking: (yieldId: string) => yieldId is "bittensor-native-staking";
|
|
@@ -1,7 +1,9 @@
|
|
|
1
1
|
import type { TokenDto } from "../../domain/types/tokens";
|
|
2
2
|
import { type DashboardYieldCategory } from "../../domain/types/yields";
|
|
3
|
+
import { type YieldSummary } from "./use-yield-summaries";
|
|
3
4
|
type DashboardCategoryInitialSelection = {
|
|
4
5
|
token: TokenDto;
|
|
6
|
+
yieldDto: YieldSummary;
|
|
5
7
|
yieldId: string;
|
|
6
8
|
};
|
|
7
9
|
/**
|
|
@@ -6,9 +6,10 @@ import type { InitParams } from "../../domain/types/init-params";
|
|
|
6
6
|
import type { PositionsData } from "../../domain/types/positions";
|
|
7
7
|
import { type PreferredTokenYieldsPerNetwork } from "../../domain/types/stake";
|
|
8
8
|
import type { SKWallet } from "../../domain/types/wallet";
|
|
9
|
-
import { type ValidatorsConfig, type Yield } from "../../domain/types/yields";
|
|
9
|
+
import { type DashboardYieldCategory, type ValidatorsConfig, type Yield } from "../../domain/types/yields";
|
|
10
10
|
import { useApiClient } from "../../providers/api/api-client-provider";
|
|
11
|
-
|
|
11
|
+
import { type YieldSummaryWithProvider } from "./use-yield-summaries";
|
|
12
|
+
export declare const useStreamYieldSummaries: (yieldIds: ReadonlyArray<string>) => YieldSummaryWithProvider[];
|
|
12
13
|
export declare const useMultiYields: <T = Yield[]>(yieldIds: ReadonlyArray<string>, opts?: {
|
|
13
14
|
select?: (val: Yield[]) => T;
|
|
14
15
|
enabled?: boolean;
|
|
@@ -21,14 +22,16 @@ declare const firstEligibleYield$: (args: {
|
|
|
21
22
|
isConnected: boolean;
|
|
22
23
|
network: SKWallet["network"];
|
|
23
24
|
yieldIds: ReadonlyArray<string>;
|
|
25
|
+
dashboardYieldCategory?: DashboardYieldCategory | null;
|
|
24
26
|
initParams: InitParams;
|
|
25
27
|
positionsData: PositionsData;
|
|
26
28
|
tokenBalanceAmount: BigNumber;
|
|
27
29
|
validatorsConfig: ValidatorsConfig;
|
|
28
30
|
preferredTokenYieldsPerNetwork: PreferredTokenYieldsPerNetwork | null;
|
|
29
31
|
}) => Observable<Yield | null>;
|
|
30
|
-
export declare const getCachedFirstEligibleYield: ({ queryClient, yieldIds, }: {
|
|
32
|
+
export declare const getCachedFirstEligibleYield: ({ queryClient, yieldIds, dashboardYieldCategory, }: {
|
|
31
33
|
queryClient: QueryClient;
|
|
32
34
|
yieldIds: ReadonlyArray<string>;
|
|
35
|
+
dashboardYieldCategory?: DashboardYieldCategory | null;
|
|
33
36
|
}) => import("purify-ts/Maybe").Maybe<Yield>;
|
|
34
37
|
export {};
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import type { QueryClient } from "@tanstack/react-query";
|
|
2
2
|
import { EitherAsync } from "purify-ts";
|
|
3
|
-
import { type Yield } from "../../../domain/types/yields";
|
|
3
|
+
import { type Yield, type YieldBase } from "../../../domain/types/yields";
|
|
4
4
|
import type { ApiClient } from "../../../providers/api/api-client";
|
|
5
5
|
type Params = {
|
|
6
6
|
yieldId: string;
|
|
@@ -15,10 +15,14 @@ type MultiParams = Omit<Params, "yieldId"> & {
|
|
|
15
15
|
type ParamsWithQueryClient = Params & {
|
|
16
16
|
queryClient: QueryClient;
|
|
17
17
|
};
|
|
18
|
+
type ParamsWithYieldDto = Omit<ParamsWithQueryClient, "yieldId"> & {
|
|
19
|
+
yieldDto: YieldBase;
|
|
20
|
+
};
|
|
18
21
|
type MultiParamsWithQueryClient = MultiParams & {
|
|
19
22
|
queryClient: QueryClient;
|
|
20
23
|
};
|
|
21
24
|
export declare const getYieldOpportunity: (params: ParamsWithQueryClient) => EitherAsync<Error, Yield>;
|
|
25
|
+
export declare const getYieldOpportunityFromSummary: (params: ParamsWithYieldDto) => EitherAsync<Error, Yield>;
|
|
22
26
|
export declare const getYieldOpportunities: (params: MultiParamsWithQueryClient) => EitherAsync<Error, Yield[]>;
|
|
23
27
|
export declare const queryFn: (params: ParamsWithQueryClient & {
|
|
24
28
|
signal?: AbortSignal;
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
import type { QueryClient } from "@tanstack/react-query";
|
|
2
|
+
import type { YieldProviderDetails } from "../../domain/types/yields";
|
|
3
|
+
import type { ApiClient } from "../../providers/api/api-client";
|
|
4
|
+
export declare const fetchYieldProvider: ({ client, providerId, queryClient, }: {
|
|
5
|
+
client: ReturnType<ApiClient["withOptions"]>;
|
|
6
|
+
providerId: string;
|
|
7
|
+
queryClient: QueryClient;
|
|
8
|
+
}) => Promise<YieldProviderDetails | undefined>;
|
|
9
|
+
export declare const fetchYieldProviders: ({ client, providerIds, queryClient, }: {
|
|
10
|
+
client: ReturnType<ApiClient["withOptions"]>;
|
|
11
|
+
providerIds: ReadonlyArray<string>;
|
|
12
|
+
queryClient: QueryClient;
|
|
13
|
+
}) => Promise<Map<string, import("../../generated/api/yield").ProviderDto>>;
|
|
@@ -1,13 +1,17 @@
|
|
|
1
|
+
import type { QueryClient } from "@tanstack/react-query";
|
|
2
|
+
import { type YieldProviderDetails } from "../../domain/types/yields";
|
|
1
3
|
import type { YieldDto, YieldsControllerGetYieldsParams } from "../../generated/api/yield";
|
|
2
4
|
import type { useApiClient } from "../../providers/api/api-client-provider";
|
|
3
5
|
/**
|
|
4
6
|
* A yield "summary" is the new yields API DTO, returned by
|
|
5
7
|
* `YieldsControllerGetYields`. It contains everything category discovery and
|
|
6
8
|
* list rendering need (`token`, `rewardRate`, `status`, `metadata`,
|
|
7
|
-
* `mechanics.type`, `providerId`)
|
|
8
|
-
* `__fallback__` hydration, which is only required for a selected yield.
|
|
9
|
+
* `mechanics.type`, `providerId`).
|
|
9
10
|
*/
|
|
10
11
|
export type YieldSummary = YieldDto;
|
|
12
|
+
export type YieldSummaryWithProvider = YieldSummary & {
|
|
13
|
+
provider?: YieldProviderDetails;
|
|
14
|
+
};
|
|
11
15
|
export declare const DEFAULT_YIELD_SUMMARIES_PAGE_LIMIT = 50;
|
|
12
16
|
export type YieldSummariesParams = Pick<YieldsControllerGetYieldsParams, "network" | "types" | "inputToken" | "sort" | "limit">;
|
|
13
17
|
/**
|
|
@@ -32,6 +36,9 @@ type FetchByIdsArgs = {
|
|
|
32
36
|
suppressRichErrors?: boolean;
|
|
33
37
|
yieldIds: ReadonlyArray<string>;
|
|
34
38
|
};
|
|
39
|
+
type FetchByIdsWithProvidersArgs = FetchByIdsArgs & {
|
|
40
|
+
queryClient: QueryClient;
|
|
41
|
+
};
|
|
35
42
|
/**
|
|
36
43
|
* Fetch a single page of yield summaries.
|
|
37
44
|
*/
|
|
@@ -42,9 +49,5 @@ export declare const fetchYieldSummariesPage: ({ apiClient, params, signal, }: F
|
|
|
42
49
|
* requested ID.
|
|
43
50
|
*/
|
|
44
51
|
export declare const fetchYieldSummariesByIds: ({ apiClient, chunkSize, signal, suppressRichErrors, yieldIds, }: FetchByIdsArgs) => Promise<YieldSummary[]>;
|
|
45
|
-
|
|
46
|
-
* Fetch every page of yield summaries for the given params, looping `offset`
|
|
47
|
-
* until all `total` items have been retrieved.
|
|
48
|
-
*/
|
|
49
|
-
export declare const fetchAllYieldSummaries: ({ apiClient, params, signal, }: FetchArgs) => Promise<YieldSummary[]>;
|
|
52
|
+
export declare const fetchYieldSummariesWithProvidersByIds: ({ apiClient, queryClient, signal, suppressRichErrors, yieldIds, }: FetchByIdsWithProvidersArgs) => Promise<YieldSummaryWithProvider[]>;
|
|
50
53
|
export {};
|
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
import type { TransactionType } from "../../../domain/types/action";
|
|
2
|
+
import type { PageCta } from "../../components/page-cta";
|
|
2
3
|
export declare const useComplete: () => {
|
|
3
4
|
urls: {
|
|
4
5
|
type: TransactionType;
|
|
@@ -7,4 +8,5 @@ export declare const useComplete: () => {
|
|
|
7
8
|
unstakeMatch: boolean;
|
|
8
9
|
pendingActionMatch: boolean;
|
|
9
10
|
onViewTransactionClick: (url: string) => import("purify-ts/Maybe").Maybe<Window & typeof globalThis>;
|
|
11
|
+
cta: PageCta;
|
|
10
12
|
};
|
|
@@ -1,6 +1,8 @@
|
|
|
1
1
|
import { type PropsWithChildren } from "react";
|
|
2
2
|
import type { TransactionType } from "../../../domain/types/action";
|
|
3
|
+
import type { PageCta } from "../../components/page-cta";
|
|
3
4
|
type CompleteCommonContextType = {
|
|
5
|
+
cta: PageCta;
|
|
4
6
|
urls: {
|
|
5
7
|
type: TransactionType;
|
|
6
8
|
url: string;
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
export type PageCta = {
|
|
2
|
+
disabled: boolean;
|
|
3
|
+
hide?: boolean;
|
|
4
|
+
isLoading: boolean;
|
|
5
|
+
label: string;
|
|
6
|
+
onClick: () => void;
|
|
7
|
+
variant?: "primary" | "secondary";
|
|
8
|
+
} | null;
|
|
9
|
+
export declare const PageCtaButton: ({ cta }: {
|
|
10
|
+
cta: PageCta;
|
|
11
|
+
}) => import("react/jsx-runtime").JSX.Element | null;
|
|
@@ -1,13 +1,9 @@
|
|
|
1
1
|
import type { TokenBalanceScanResponseDto } from "../../../../../domain/types/token-balance";
|
|
2
|
-
import type { TokenMaxYieldRate } from "../../../../../hooks/api/use-token-list-yields";
|
|
3
2
|
type Props = {
|
|
4
3
|
item: TokenBalanceScanResponseDto;
|
|
5
4
|
isConnected: boolean;
|
|
6
5
|
isSelected: boolean;
|
|
7
|
-
availableYieldsCount?: number;
|
|
8
|
-
canSelectToken?: boolean;
|
|
9
|
-
maxYieldRate?: TokenMaxYieldRate;
|
|
10
6
|
onTokenBalanceSelect: (tokenBalance: TokenBalanceScanResponseDto) => void;
|
|
11
7
|
};
|
|
12
|
-
export declare const SelectTokenListItem: import("react").MemoExoticComponent<({ item, isConnected, isSelected,
|
|
8
|
+
export declare const SelectTokenListItem: import("react").MemoExoticComponent<({ item, isConnected, isSelected, onTokenBalanceSelect }: Props) => import("react/jsx-runtime").JSX.Element>;
|
|
13
9
|
export {};
|
|
@@ -36,8 +36,6 @@ export declare const selectTokenBalance: import("@vanilla-extract/recipes").Runt
|
|
|
36
36
|
porto: {};
|
|
37
37
|
};
|
|
38
38
|
}>;
|
|
39
|
-
export declare const maxYieldRateText: string;
|
|
40
|
-
export declare const maxYieldRateLabel: string;
|
|
41
39
|
export declare const minMaxContainer: import("@vanilla-extract/recipes").RuntimeFn<{
|
|
42
40
|
variant: {
|
|
43
41
|
default: string;
|
|
@@ -6,26 +6,26 @@ import type { TokenDto } from "../../../../domain/types/tokens";
|
|
|
6
6
|
import type { TronResourceType } from "../../../../domain/types/tron";
|
|
7
7
|
import type { DashboardYieldCategory, Yield } from "../../../../domain/types/yields";
|
|
8
8
|
import type { ValidatorDto } from "../../../../generated/api/yield";
|
|
9
|
-
import type { TokenMaxYieldRate } from "../../../../hooks/api/use-token-list-yields";
|
|
10
9
|
import type { useEstimatedRewards } from "../../../../hooks/use-estimated-rewards";
|
|
11
10
|
import type { useProvidersDetails } from "../../../../hooks/use-provider-details";
|
|
12
11
|
import type { useRewardTokenDetails } from "../../../../hooks/use-reward-token-details";
|
|
13
12
|
import type { Action } from "../../../../types/utils";
|
|
13
|
+
import type { PageCta } from "../../../components/page-cta";
|
|
14
14
|
import type { SelectedStakeData } from "../types";
|
|
15
15
|
export type State = {
|
|
16
16
|
selectedToken: Maybe<TokenDto>;
|
|
17
17
|
selectedStakeId: Maybe<TokenBalanceScanResponseDto["availableYields"][number]>;
|
|
18
|
+
autoSelectYield: boolean;
|
|
18
19
|
selectedValidators: Map<ValidatorDto["address"], ValidatorDto>;
|
|
19
20
|
stakeAmount: BigNumber;
|
|
20
21
|
useMaxAmount: boolean;
|
|
21
22
|
tronResource: Maybe<TronResourceType>;
|
|
22
23
|
selectedProviderYieldId: Maybe<Yield["id"]>;
|
|
24
|
+
selectedDashboardYieldCategory: DashboardYieldCategory | null;
|
|
23
25
|
};
|
|
24
26
|
type TokenBalanceSelectAction = Action<"token/select", TokenDto>;
|
|
25
|
-
type
|
|
26
|
-
|
|
27
|
-
yieldDto: Yield;
|
|
28
|
-
}>;
|
|
27
|
+
type DashboardYieldCategorySelectAction = Action<"dashboard/yield-category/select", DashboardYieldCategory>;
|
|
28
|
+
type PositionDetailsStakeInitializeAction = Action<"positionDetails/stake/initialize", Yield>;
|
|
29
29
|
type YieldSelectAction = Action<"yield/select", Yield>;
|
|
30
30
|
type StakeAmountChangeAction = Action<"stakeAmount/change", BigNumber>;
|
|
31
31
|
type StakeAmountMaxAction = Action<"stakeAmount/max", BigNumber>;
|
|
@@ -35,7 +35,7 @@ type ValidatorMultiSelectAction = Action<"validator/multiselect", ValidatorDto>;
|
|
|
35
35
|
type ValidatorRemoveAction = Action<"validator/remove", ValidatorDto>;
|
|
36
36
|
type SelectTronResourceAction = Action<"tronResource/select", TronResourceType>;
|
|
37
37
|
type ProviderYieldIdSelectAction = Action<"providerYieldId/select", Yield["id"]>;
|
|
38
|
-
export type Actions = TokenBalanceSelectAction |
|
|
38
|
+
export type Actions = TokenBalanceSelectAction | DashboardYieldCategorySelectAction | PositionDetailsStakeInitializeAction | YieldSelectAction | StakeAmountChangeAction | StakeAmountMaxAction | StateResetAction | ValidatorSelectAction | ValidatorMultiSelectAction | ValidatorRemoveAction | SelectTronResourceAction | ProviderYieldIdSelectAction;
|
|
39
39
|
export type ExtraData = {
|
|
40
40
|
actions: {
|
|
41
41
|
onMaxClick: () => void;
|
|
@@ -48,8 +48,10 @@ export type ExtraData = {
|
|
|
48
48
|
availableAmount: Maybe<BigNumber>;
|
|
49
49
|
availableYields: Maybe<TokenBalanceScanResponseDto["availableYields"]>;
|
|
50
50
|
hasNotYieldsForToken: boolean;
|
|
51
|
+
availableDashboardYieldCategories: DashboardYieldCategory[];
|
|
51
52
|
};
|
|
52
53
|
export type EarnPageContextType = {
|
|
54
|
+
cta: PageCta;
|
|
53
55
|
selectedTokenAvailableAmount: Maybe<{
|
|
54
56
|
symbol: string;
|
|
55
57
|
shortFormattedAmount: string;
|
|
@@ -97,9 +99,6 @@ export type EarnPageContextType = {
|
|
|
97
99
|
all: TokenBalanceScanResponseDto[];
|
|
98
100
|
filtered: TokenBalanceScanResponseDto[];
|
|
99
101
|
}>;
|
|
100
|
-
tokenMaxYieldRatesByToken: ReadonlyMap<string, TokenMaxYieldRate>;
|
|
101
|
-
tokenYieldCountsByToken: ReadonlyMap<string, number>;
|
|
102
|
-
tokenListYieldsIsLoading: boolean;
|
|
103
102
|
onTokenSearch: (value: string) => void;
|
|
104
103
|
onValidatorSearch: (value: string) => void;
|
|
105
104
|
validatorSearch: string;
|
|
@@ -1,4 +1,6 @@
|
|
|
1
1
|
import type { TokenDto } from "../../../../domain/types/tokens";
|
|
2
|
-
|
|
2
|
+
import type { DashboardYieldCategory } from "../../../../domain/types/yields";
|
|
3
|
+
export declare const useGetInitYield: () => ({ selectedDashboardYieldCategory, selectedToken, }: {
|
|
4
|
+
selectedDashboardYieldCategory?: DashboardYieldCategory | null;
|
|
3
5
|
selectedToken: TokenDto;
|
|
4
6
|
}) => import("purify-ts/Maybe").Maybe<import("../../../../domain/types/yields").Yield>;
|
|
@@ -1,5 +1,7 @@
|
|
|
1
1
|
import { Maybe } from "purify-ts";
|
|
2
2
|
import type { TokenDto } from "../../../../domain/types/tokens";
|
|
3
|
-
|
|
3
|
+
import type { DashboardYieldCategory } from "../../../../domain/types/yields";
|
|
4
|
+
export declare const useInitYield: ({ selectedDashboardYieldCategory, selectedToken, }: {
|
|
5
|
+
selectedDashboardYieldCategory?: DashboardYieldCategory | null;
|
|
4
6
|
selectedToken: Maybe<TokenDto>;
|
|
5
7
|
}) => import("@tanstack/react-query").UseQueryResult<import("../../../../domain/types/yields").Yield | null, Error>;
|