@ecency/wallets 1.4.25 → 1.4.27
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/browser/index.d.ts +33 -6
- package/dist/browser/index.js +693 -249
- package/dist/browser/index.js.map +1 -1
- package/dist/node/index.cjs +696 -248
- package/dist/node/index.cjs.map +1 -1
- package/dist/node/index.mjs +693 -249
- package/dist/node/index.mjs.map +1 -1
- package/package.json +2 -2
package/dist/browser/index.d.ts
CHANGED
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import * as _tanstack_react_query from '@tanstack/react-query';
|
|
2
2
|
import { UseMutationOptions, useMutation } from '@tanstack/react-query';
|
|
3
3
|
import { BaseWallet, SignTxParams } from '@okxweb3/coin-base';
|
|
4
|
-
import { OperationName, VirtualOperationName, SMTAsset, PrivateKey, Client } from '@hiveio/dhive';
|
|
5
|
-
import { Transaction, SignedTransaction, TransactionConfirmation } from '@hiveio/dhive/lib/chain/transaction';
|
|
4
|
+
import { OperationName, VirtualOperationName, SMTAsset, PrivateKey, Operation, TransactionConfirmation, Client } from '@hiveio/dhive';
|
|
5
|
+
import { Transaction, SignedTransaction, TransactionConfirmation as TransactionConfirmation$1 } from '@hiveio/dhive/lib/chain/transaction';
|
|
6
6
|
import { utxoTx } from '@okxweb3/coin-bitcoin/dist/type';
|
|
7
7
|
import { Network } from '@okxweb3/coin-bitcoin/dist/bitcoinjs-lib';
|
|
8
8
|
import { EthTxParams } from '@okxweb3/coin-ethereum/dist/EthWallet';
|
|
@@ -796,7 +796,7 @@ interface GeneralAssetTransaction {
|
|
|
796
796
|
memo?: string;
|
|
797
797
|
}
|
|
798
798
|
|
|
799
|
-
type HiveBasedAssetSignType = "key" | "keychain" | "hivesigner";
|
|
799
|
+
type HiveBasedAssetSignType = "key" | "keychain" | "hivesigner" | "hiveauth";
|
|
800
800
|
|
|
801
801
|
interface TransferPayload<T extends HiveBasedAssetSignType> {
|
|
802
802
|
from: string;
|
|
@@ -922,6 +922,14 @@ declare function vestsToHp(vests: number, hivePerMVests: number): number;
|
|
|
922
922
|
|
|
923
923
|
declare function rewardSpk(data: SpkApiWallet, sstats: any): number;
|
|
924
924
|
|
|
925
|
+
type HiveAuthKeyType$1 = "posting" | "active";
|
|
926
|
+
type HiveAuthBroadcastHandler = (username: string, operations: Operation[], keyType: HiveAuthKeyType$1) => Promise<TransactionConfirmation>;
|
|
927
|
+
|
|
928
|
+
type HiveAuthKeyType = "posting" | "active";
|
|
929
|
+
declare function registerWalletHiveAuthBroadcast(handler: HiveAuthBroadcastHandler): void;
|
|
930
|
+
declare function broadcastWithWalletHiveAuth(username: string, operations: Operation[], keyType: HiveAuthKeyType): Promise<TransactionConfirmation>;
|
|
931
|
+
declare function hasWalletHiveAuthBroadcast(): boolean;
|
|
932
|
+
|
|
925
933
|
interface SpkTransferPayload<T extends HiveBasedAssetSignType> {
|
|
926
934
|
from: string;
|
|
927
935
|
to: string;
|
|
@@ -1383,7 +1391,7 @@ declare function transferEngineToken<T extends HiveBasedAssetSignType>(payload:
|
|
|
1383
1391
|
|
|
1384
1392
|
declare function useClaimPoints(username: string | undefined, onSuccess?: () => void, onError?: Parameters<typeof useMutation>["0"]["onError"]): _tanstack_react_query.UseMutationResult<Response, unknown, unknown, unknown>;
|
|
1385
1393
|
|
|
1386
|
-
type PointsSignType = "key" | "keychain" | "hivesigner";
|
|
1394
|
+
type PointsSignType = "key" | "keychain" | "hivesigner" | "hiveauth";
|
|
1387
1395
|
interface PointsTransferPayloadBase {
|
|
1388
1396
|
from: string;
|
|
1389
1397
|
to: string;
|
|
@@ -1628,6 +1636,25 @@ declare function getTokenOperationsQueryOptions(token: string, username: string,
|
|
|
1628
1636
|
|
|
1629
1637
|
declare function useWalletsCacheQuery(username?: string): _tanstack_react_query.DefinedUseQueryResult<Map<EcencyWalletCurrency, EcencyTokenMetadata>, Error>;
|
|
1630
1638
|
|
|
1639
|
+
interface VisionPortfolioWalletItem {
|
|
1640
|
+
symbol: string;
|
|
1641
|
+
info: GeneralAssetInfo;
|
|
1642
|
+
operations: AssetOperation[];
|
|
1643
|
+
}
|
|
1644
|
+
interface VisionPortfolioResponse {
|
|
1645
|
+
username: string;
|
|
1646
|
+
currency?: string;
|
|
1647
|
+
wallets: VisionPortfolioWalletItem[];
|
|
1648
|
+
}
|
|
1649
|
+
declare function getVisionPortfolioQueryOptions(username: string): _tanstack_react_query.OmitKeyof<_tanstack_react_query.UseQueryOptions<VisionPortfolioResponse, Error, VisionPortfolioResponse, string[]>, "queryFn"> & {
|
|
1650
|
+
queryFn?: _tanstack_react_query.QueryFunction<VisionPortfolioResponse, string[], never> | undefined;
|
|
1651
|
+
} & {
|
|
1652
|
+
queryKey: string[] & {
|
|
1653
|
+
[dataTagSymbol]: VisionPortfolioResponse;
|
|
1654
|
+
[dataTagErrorSymbol]: Error;
|
|
1655
|
+
};
|
|
1656
|
+
};
|
|
1657
|
+
|
|
1631
1658
|
declare function delay(ms: number): Promise<unknown>;
|
|
1632
1659
|
|
|
1633
1660
|
declare function getWallet(currency: EcencyWalletCurrency): BaseWallet | undefined;
|
|
@@ -1696,7 +1723,7 @@ declare function signTx(tx: Transaction, privateKey: string, chainId?: string):
|
|
|
1696
1723
|
* @param chainId Optional chain id as a hex string.
|
|
1697
1724
|
* @returns Broadcast confirmation.
|
|
1698
1725
|
*/
|
|
1699
|
-
declare function signTxAndBroadcast(client: Client, tx: Transaction, privateKey: string, chainId?: string): Promise<TransactionConfirmation>;
|
|
1726
|
+
declare function signTxAndBroadcast(client: Client, tx: Transaction, privateKey: string, chainId?: string): Promise<TransactionConfirmation$1>;
|
|
1700
1727
|
|
|
1701
1728
|
/**
|
|
1702
1729
|
* Encrypt a memo using explicit keys.
|
|
@@ -1787,4 +1814,4 @@ declare function buildExternalTx(currency: EcencyWalletCurrency, tx: ExternalTxP
|
|
|
1787
1814
|
|
|
1788
1815
|
declare function getBoundFetch(): typeof fetch;
|
|
1789
1816
|
|
|
1790
|
-
export { type AccountPointsResponse, type Asset, AssetOperation, type AuthorReward, type CancelTransferFromSavings, type ClaimRewardBalance, type CollateralizedConvert, type CommentBenefactor, type CommentPayoutUpdate, type CommentReward, type CurationReward, type DelegateEnginePayload, type DelegateVestingShares, type DelegatedVestingShare, type EcencyHiveKeys, type EcencyTokenMetadata, EcencyWalletBasicTokens, EcencyWalletCurrency, index as EcencyWalletsPrivateApi, type EffectiveCommentVote, type ExternalTxParams, type ExternalWalletBalance, type FillCollateralizedConvertRequest, type FillConvertRequest, type FillOrder, type FillRecurrentTransfers, type FillVestingWithdraw, type GeneralAssetInfo, type GeneralAssetTransaction, HIVE_ACCOUNT_OPERATION_GROUPS, HIVE_OPERATION_LIST, HIVE_OPERATION_NAME_BY_ID, HIVE_OPERATION_ORDERS, type HiveBasedAssetSignType, type HiveEngineMarketResponse, type HiveEngineMetric, type HiveEngineTokenBalance, type HiveEngineTokenMetadataResponse, type HiveEngineTransaction, type HiveKeyDerivation, type HiveMarketMetric, type HiveOperationFilter, type HiveOperationFilterKey, type HiveOperationFilterValue, type HiveOperationGroup, type HiveOperationName, type HiveRole, type HiveTransaction, type HiveWithdrawRoute, type Interest, type LimitOrderCancel, type LimitOrderCreate, NaiMap, type PointTransaction, PointTransactionType, type Points, type PointsResponse, type ProducerReward, type ProposalPay, type ReceivedVestingShare, type RecurrentTransfers, type ReturnVestingDelegation, type SetWithdrawRoute, type SpkApiWallet, type SpkMarkets, type StakeEnginePayload, Symbol, type Transfer, type TransferEnginePayload, type TransferPayload, type TransferToSavings, type TransferToVesting, type TransformedSpkMarkets, type UndelegateEnginePayload, type UnstakeEnginePayload, type UpdateProposalVotes, type VoteProxy, type WithdrawVesting, buildAptTx, buildEthTx, buildExternalTx, buildPsbt, buildSolTx, buildTonTx, buildTronTx, claimInterestHive, decryptMemoWithAccounts, decryptMemoWithKeys, delay, delegateEngineToken, delegateHive, deriveHiveKey, deriveHiveKeys, deriveHiveMasterPasswordKey, deriveHiveMasterPasswordKeys, detectHiveKeyDerivation, encryptMemoWithAccounts, encryptMemoWithKeys, getAccountWalletAssetInfoQueryOptions, getAccountWalletListQueryOptions, getAllTokensListQueryOptions, getBoundFetch, getHbdAssetGeneralInfoQueryOptions, getHbdAssetTransactionsQueryOptions, getHiveAssetGeneralInfoQueryOptions, getHiveAssetMetricQueryOptions, getHiveAssetTransactionsQueryOptions, getHiveAssetWithdrawalRoutesQueryOptions, getHiveEngineTokenGeneralInfoQueryOptions, getHiveEngineTokenTransactionsQueryOptions, getHiveEngineTokensBalancesQueryOptions, getHiveEngineTokensMarketQueryOptions, getHiveEngineTokensMetadataQueryOptions, getHiveEngineTokensMetricsQueryOptions, getHivePowerAssetGeneralInfoQueryOptions, getHivePowerAssetTransactionsQueryOptions, getHivePowerDelegatesInfiniteQueryOptions, getHivePowerDelegatingsQueryOptions, getLarynxAssetGeneralInfoQueryOptions, getLarynxPowerAssetGeneralInfoQueryOptions, getPointsAssetGeneralInfoQueryOptions, getPointsAssetTransactionsQueryOptions, getPointsQueryOptions, getSpkAssetGeneralInfoQueryOptions, getSpkMarketsQueryOptions, getTokenOperationsQueryOptions, getTokenPriceQueryOptions, getWallet, isEmptyDate, lockLarynx, mnemonicToSeedBip39, parseAsset, powerDownHive, powerUpHive, powerUpLarynx, resolveHiveOperationFilters, rewardSpk, signDigest, signExternalTx, signExternalTxAndBroadcast, signTx, signTxAndBroadcast, stakeEngineToken, transferEngineToken, transferFromSavingsHive, transferHive, transferLarynx, transferPoint, transferSpk, transferToSavingsHive, undelegateEngineToken, unstakeEngineToken, useClaimPoints, useClaimRewards, useGetExternalWalletBalanceQuery, useHiveKeysQuery, useImportWallet, useSaveWalletInformationToMetadata, useSeedPhrase, useWalletCreate, useWalletOperation, useWalletsCacheQuery, vestsToHp, withdrawVestingRouteHive };
|
|
1817
|
+
export { type AccountPointsResponse, type Asset, AssetOperation, type AuthorReward, type CancelTransferFromSavings, type ClaimRewardBalance, type CollateralizedConvert, type CommentBenefactor, type CommentPayoutUpdate, type CommentReward, type CurationReward, type DelegateEnginePayload, type DelegateVestingShares, type DelegatedVestingShare, type EcencyHiveKeys, type EcencyTokenMetadata, EcencyWalletBasicTokens, EcencyWalletCurrency, index as EcencyWalletsPrivateApi, type EffectiveCommentVote, type ExternalTxParams, type ExternalWalletBalance, type FillCollateralizedConvertRequest, type FillConvertRequest, type FillOrder, type FillRecurrentTransfers, type FillVestingWithdraw, type GeneralAssetInfo, type GeneralAssetTransaction, HIVE_ACCOUNT_OPERATION_GROUPS, HIVE_OPERATION_LIST, HIVE_OPERATION_NAME_BY_ID, HIVE_OPERATION_ORDERS, type HiveAuthBroadcastHandler, type HiveAuthKeyType, type HiveBasedAssetSignType, type HiveEngineMarketResponse, type HiveEngineMetric, type HiveEngineTokenBalance, type HiveEngineTokenMetadataResponse, type HiveEngineTransaction, type HiveKeyDerivation, type HiveMarketMetric, type HiveOperationFilter, type HiveOperationFilterKey, type HiveOperationFilterValue, type HiveOperationGroup, type HiveOperationName, type HiveRole, type HiveTransaction, type HiveWithdrawRoute, type Interest, type LimitOrderCancel, type LimitOrderCreate, NaiMap, type PointTransaction, PointTransactionType, type Points, type PointsResponse, type ProducerReward, type ProposalPay, type ReceivedVestingShare, type RecurrentTransfers, type ReturnVestingDelegation, type SetWithdrawRoute, type SpkApiWallet, type SpkMarkets, type StakeEnginePayload, Symbol, type Transfer, type TransferEnginePayload, type TransferPayload, type TransferToSavings, type TransferToVesting, type TransformedSpkMarkets, type UndelegateEnginePayload, type UnstakeEnginePayload, type UpdateProposalVotes, type VisionPortfolioResponse, type VisionPortfolioWalletItem, type VoteProxy, type WithdrawVesting, broadcastWithWalletHiveAuth, buildAptTx, buildEthTx, buildExternalTx, buildPsbt, buildSolTx, buildTonTx, buildTronTx, claimInterestHive, decryptMemoWithAccounts, decryptMemoWithKeys, delay, delegateEngineToken, delegateHive, deriveHiveKey, deriveHiveKeys, deriveHiveMasterPasswordKey, deriveHiveMasterPasswordKeys, detectHiveKeyDerivation, encryptMemoWithAccounts, encryptMemoWithKeys, getAccountWalletAssetInfoQueryOptions, getAccountWalletListQueryOptions, getAllTokensListQueryOptions, getBoundFetch, getHbdAssetGeneralInfoQueryOptions, getHbdAssetTransactionsQueryOptions, getHiveAssetGeneralInfoQueryOptions, getHiveAssetMetricQueryOptions, getHiveAssetTransactionsQueryOptions, getHiveAssetWithdrawalRoutesQueryOptions, getHiveEngineTokenGeneralInfoQueryOptions, getHiveEngineTokenTransactionsQueryOptions, getHiveEngineTokensBalancesQueryOptions, getHiveEngineTokensMarketQueryOptions, getHiveEngineTokensMetadataQueryOptions, getHiveEngineTokensMetricsQueryOptions, getHivePowerAssetGeneralInfoQueryOptions, getHivePowerAssetTransactionsQueryOptions, getHivePowerDelegatesInfiniteQueryOptions, getHivePowerDelegatingsQueryOptions, getLarynxAssetGeneralInfoQueryOptions, getLarynxPowerAssetGeneralInfoQueryOptions, getPointsAssetGeneralInfoQueryOptions, getPointsAssetTransactionsQueryOptions, getPointsQueryOptions, getSpkAssetGeneralInfoQueryOptions, getSpkMarketsQueryOptions, getTokenOperationsQueryOptions, getTokenPriceQueryOptions, getVisionPortfolioQueryOptions, getWallet, hasWalletHiveAuthBroadcast, isEmptyDate, lockLarynx, mnemonicToSeedBip39, parseAsset, powerDownHive, powerUpHive, powerUpLarynx, registerWalletHiveAuthBroadcast, resolveHiveOperationFilters, rewardSpk, signDigest, signExternalTx, signExternalTxAndBroadcast, signTx, signTxAndBroadcast, stakeEngineToken, transferEngineToken, transferFromSavingsHive, transferHive, transferLarynx, transferPoint, transferSpk, transferToSavingsHive, undelegateEngineToken, unstakeEngineToken, useClaimPoints, useClaimRewards, useGetExternalWalletBalanceQuery, useHiveKeysQuery, useImportWallet, useSaveWalletInformationToMetadata, useSeedPhrase, useWalletCreate, useWalletOperation, useWalletsCacheQuery, vestsToHp, withdrawVestingRouteHive };
|