@exodus/asset-types 0.5.1 → 0.6.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +18 -0
- package/package.json +2 -2
- package/src/asset.d.ts +12 -17
package/CHANGELOG.md
CHANGED
|
@@ -3,6 +3,24 @@
|
|
|
3
3
|
All notable changes to this project will be documented in this file.
|
|
4
4
|
See [Conventional Commits](https://conventionalcommits.org) for commit guidelines.
|
|
5
5
|
|
|
6
|
+
## [0.6.0](https://github.com/ExodusMovement/assets/compare/@exodus/asset-types@0.5.1...@exodus/asset-types@0.6.0) (2026-05-18)
|
|
7
|
+
|
|
8
|
+
|
|
9
|
+
### Features
|
|
10
|
+
|
|
11
|
+
|
|
12
|
+
* feat: add Asset type (#8070)
|
|
13
|
+
|
|
14
|
+
|
|
15
|
+
### Bug Fixes
|
|
16
|
+
|
|
17
|
+
|
|
18
|
+
* fix(asset-types): correct stakeable balance field spelling (#8097)
|
|
19
|
+
|
|
20
|
+
* fix: declare phantom dependencies across workspaces (#7833)
|
|
21
|
+
|
|
22
|
+
|
|
23
|
+
|
|
6
24
|
## [0.5.1](https://github.com/ExodusMovement/assets/compare/@exodus/asset-types@0.5.0...@exodus/asset-types@0.5.1) (2026-03-26)
|
|
7
25
|
|
|
8
26
|
**Note:** Version bump only for package @exodus/asset-types
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@exodus/asset-types",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "0.6.0",
|
|
4
4
|
"description": "Typings for Assets",
|
|
5
5
|
"author": "Exodus Movement, Inc.",
|
|
6
6
|
"repository": {
|
|
@@ -42,5 +42,5 @@
|
|
|
42
42
|
"access": "public",
|
|
43
43
|
"provenance": false
|
|
44
44
|
},
|
|
45
|
-
"gitHead": "
|
|
45
|
+
"gitHead": "c30e0d78dc67aede7ad6b3095d0f03a14be6270e"
|
|
46
46
|
}
|
package/src/asset.d.ts
CHANGED
|
@@ -3,7 +3,6 @@
|
|
|
3
3
|
import type NumberUnit from '@exodus/currency'
|
|
4
4
|
import type KeyIdentifier from '@exodus/key-identifier'
|
|
5
5
|
import type { AccountState, Tx, TxSet } from '@exodus/models'
|
|
6
|
-
import type BN from 'bn.js'
|
|
7
6
|
|
|
8
7
|
import type { AssetMeta } from './asset-meta.js'
|
|
9
8
|
import type { WalletAccountLike } from './common.js'
|
|
@@ -61,7 +60,7 @@ export type BalanceFieldName =
|
|
|
61
60
|
| 'networkReserve'
|
|
62
61
|
| 'staking'
|
|
63
62
|
| 'staked'
|
|
64
|
-
| '
|
|
63
|
+
| 'stakeable'
|
|
65
64
|
| 'unstaking'
|
|
66
65
|
| 'unstaked'
|
|
67
66
|
| 'rewards'
|
|
@@ -69,19 +68,12 @@ export type BalanceFieldName =
|
|
|
69
68
|
|
|
70
69
|
export type Balances = Record<BalanceFieldName, NumberUnit>
|
|
71
70
|
|
|
72
|
-
export type UnsignedTxPayload
|
|
73
|
-
txData: Extendable<
|
|
74
|
-
to: string
|
|
75
|
-
amount: NumberValue
|
|
76
|
-
fee: NumberValue
|
|
77
|
-
gasPrice: NumberValue
|
|
78
|
-
gasLimit: NumberValue
|
|
79
|
-
nonce: NumberValue
|
|
80
|
-
}>
|
|
71
|
+
export type UnsignedTxPayload = {
|
|
72
|
+
txData: Extendable<object>
|
|
81
73
|
txMeta: Extendable<{
|
|
82
74
|
assetName: string
|
|
83
75
|
}>
|
|
84
|
-
}
|
|
76
|
+
}
|
|
85
77
|
|
|
86
78
|
export type SignTransactionParams = Extendable<{
|
|
87
79
|
assetName: string
|
|
@@ -210,11 +202,12 @@ export type AbstractAsset = AssetMeta & {
|
|
|
210
202
|
toString(): string
|
|
211
203
|
}
|
|
212
204
|
|
|
213
|
-
export type CombinedAsset<A extends BaseAsset | TokenAsset = BaseAsset | TokenAsset> =
|
|
214
|
-
|
|
215
|
-
|
|
216
|
-
|
|
217
|
-
|
|
205
|
+
export type CombinedAsset<A extends BaseAsset | TokenAsset = BaseAsset | TokenAsset> =
|
|
206
|
+
AbstractAsset & {
|
|
207
|
+
isCombined: true
|
|
208
|
+
combinedAssets: A[]
|
|
209
|
+
combinedAssetNames: A['name'][]
|
|
210
|
+
}
|
|
218
211
|
|
|
219
212
|
export type BaseAsset = AbstractAsset & {
|
|
220
213
|
api: AssetApi
|
|
@@ -225,6 +218,8 @@ export type TokenAsset = AbstractAsset & {
|
|
|
225
218
|
api: CommonAssetApi
|
|
226
219
|
}
|
|
227
220
|
|
|
221
|
+
export type Asset = BaseAsset | TokenAsset | CombinedAsset
|
|
222
|
+
|
|
228
223
|
export type AddressOverrideCallbackParams<A extends BaseAsset = BaseAsset> = { asset: A }
|
|
229
224
|
|
|
230
225
|
export type CreateAssetParams<A extends BaseAsset = BaseAsset, C = unknown> = {
|