@exodus/headless 2.0.0-alpha.31 → 2.0.0-alpha.33

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 CHANGED
@@ -3,6 +3,18 @@
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
+ ## [2.0.0-alpha.33](https://github.com/ExodusMovement/exodus-hydra/compare/@exodus/headless@2.0.0-alpha.32...@exodus/headless@2.0.0-alpha.33) (2023-06-07)
7
+
8
+ ### Features
9
+
10
+ - add apy rates monitor to headless ([#1830](https://github.com/ExodusMovement/exodus-hydra/issues/1830)) ([6040f4e](https://github.com/ExodusMovement/exodus-hydra/commit/6040f4eacc4b0ea29a25a28c21f6d4c07c833dd4))
11
+
12
+ ## [2.0.0-alpha.32](https://github.com/ExodusMovement/exodus-hydra/compare/@exodus/headless@2.0.0-alpha.31...@exodus/headless@2.0.0-alpha.32) (2023-06-06)
13
+
14
+ ### Features
15
+
16
+ - add auto enable assets to headless ([#1803](https://github.com/ExodusMovement/exodus-hydra/issues/1803)) ([11996d9](https://github.com/ExodusMovement/exodus-hydra/commit/11996d9a9b23a5d2d1ec1aa30b5e41d05e66ed6a))
17
+
6
18
  ## [2.0.0-alpha.31](https://github.com/ExodusMovement/exodus-hydra/compare/@exodus/headless@2.0.0-alpha.30...@exodus/headless@2.0.0-alpha.31) (2023-06-05)
7
19
 
8
20
  ### ⚠ BREAKING CHANGES
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@exodus/headless",
3
- "version": "2.0.0-alpha.31",
3
+ "version": "2.0.0-alpha.33",
4
4
  "description": "The headless Exodus wallet SDK",
5
5
  "author": "Exodus Movement Inc",
6
6
  "main": "src/index.js",
@@ -27,7 +27,9 @@
27
27
  },
28
28
  "dependencies": {
29
29
  "@exodus/addresses-provider": "^3.0.2",
30
+ "@exodus/apy-rates": "^2.1.0",
30
31
  "@exodus/atoms": "^3.5.3",
32
+ "@exodus/auto-enable-assets-plugin": "^4.0.1",
31
33
  "@exodus/available-assets": "^2.0.0",
32
34
  "@exodus/balances": "^6.0.0",
33
35
  "@exodus/basic-utils": "^2.0.0",
@@ -35,10 +37,10 @@
35
37
  "@exodus/config": "^7.0.0",
36
38
  "@exodus/connected-origins": "^1.1.2",
37
39
  "@exodus/crypto-news-monitor": "^2.0.0",
38
- "@exodus/dependency-injection": "^1.4.0",
39
- "@exodus/dependency-preprocessors": "^2.5.0",
40
+ "@exodus/dependency-injection": "^2.0.0",
41
+ "@exodus/dependency-preprocessors": "^2.6.0",
40
42
  "@exodus/enabled-assets": "^6.0.1",
41
- "@exodus/exodus-pricing-client": "^1.1.0",
43
+ "@exodus/exodus-pricing-client": "^1.2.0",
42
44
  "@exodus/feature-flags": "^2.0.1",
43
45
  "@exodus/fee-monitors": "^1.0.0",
44
46
  "@exodus/fetch": "^1.2.1",
@@ -76,6 +78,7 @@
76
78
  "@exodus/wild-emitter": "^1.0.0",
77
79
  "buffer-json": "^2.0.0",
78
80
  "deepmerge": "^4.2.2",
81
+ "delay": "^5.0.0",
79
82
  "eslint": "^8.33.0",
80
83
  "eslint-plugin-simple-import-sort": "^7.0.0",
81
84
  "events": "^3.3.0",
@@ -83,5 +86,5 @@
83
86
  "nock": "^13.3.1",
84
87
  "p-defer": "^4.0.0"
85
88
  },
86
- "gitHead": "57b89e99ba9a2609cc99be0b0ec355550266a936"
89
+ "gitHead": "415054e049df3eb22c79d8568bf071fdbc9c2f11"
87
90
  }
@@ -0,0 +1,10 @@
1
+ import { createInMemoryAtom } from '@exodus/atoms'
2
+
3
+ const nonDustBalanceAssetNamesAtomDefinition = {
4
+ id: 'nonDustBalanceAssetNamesAtom',
5
+ type: 'atom',
6
+ factory: () => createInMemoryAtom({ defaultValue: [] }),
7
+ dependencies: [],
8
+ }
9
+
10
+ export default nonDustBalanceAssetNamesAtomDefinition
package/src/constants.js CHANGED
@@ -1,4 +1,5 @@
1
1
  export const atomsToAttach = [
2
+ 'apyRatesAtom',
2
3
  'availableAssetNamesAtom',
3
4
  'balancesAtom',
4
5
  'cryptoNewsAtom',
@@ -1,3 +1,4 @@
1
+ import { apyRatesAtomDefinition } from '@exodus/apy-rates/atoms'
1
2
  import {
2
3
  createFusionAtomFactory,
3
4
  createInMemoryAtom,
@@ -25,6 +26,7 @@ import {
25
26
  } from '@exodus/wallet-accounts/atoms'
26
27
 
27
28
  import baseAssetNamesToMonitorAtomDefinition from '../atoms/base-asset-names-to-monitor'
29
+ import nonDustBalanceAssetNamesAtomDefinition from '../atoms/non-dust-balance-asset-names-atom'
28
30
  import restoreAtomDefinition from '../atoms/restore'
29
31
  import { withType } from './utils'
30
32
 
@@ -48,6 +50,9 @@ const createAtomDependencies = () =>
48
50
  },
49
51
  { definition: enabledAssetsAtomDefinition },
50
52
  { definition: availableAssetNamesAtomDefinition },
53
+ {
54
+ definition: nonDustBalanceAssetNamesAtomDefinition,
55
+ },
51
56
  {
52
57
  definition: {
53
58
  id: 'pricingServerUrlAtom',
@@ -163,6 +168,7 @@ const createAtomDependencies = () =>
163
168
  { definition: topMoversAtomDefinition },
164
169
  { definition: cryptoNewsAtomDefinition },
165
170
  { definition: restoreAtomDefinition },
171
+ { definition: apyRatesAtomDefinition },
166
172
  ].map(withType('atom'))
167
173
 
168
174
  export default createAtomDependencies
@@ -1,3 +1,4 @@
1
+ import apyRatesMonitorDefinition from '@exodus/apy-rates/monitor'
1
2
  import cryptoNewsMonitorDefinition from '@exodus/crypto-news-monitor/monitor'
2
3
  import feeMonitorsDefinition from '@exodus/fee-monitors/monitor'
3
4
  import geolocationMonitorDefinition from '@exodus/geolocation/monitor'
@@ -51,6 +52,10 @@ const createMonitorDependencies = ({ config }) =>
51
52
  definition: cryptoNewsMonitorDefinition,
52
53
  writesAtoms: ['cryptoNewsAtom'],
53
54
  },
55
+ {
56
+ definition: apyRatesMonitorDefinition,
57
+ writesAtoms: ['apyRatesAtom'],
58
+ },
54
59
  ].map(withType('monitor'))
55
60
 
56
61
  export default createMonitorDependencies
package/src/index.js CHANGED
@@ -33,6 +33,7 @@ const createExodus = ({ adapters, config, port }) => {
33
33
  } = ioc.getByType('module')
34
34
 
35
35
  const {
36
+ apyRatesMonitor,
36
37
  cryptoNewsMonitor,
37
38
  feeMonitors,
38
39
  geolocationMonitor,
@@ -83,6 +84,7 @@ const createExodus = ({ adapters, config, port }) => {
83
84
  marketHistory.start()
84
85
  ratesMonitor.start()
85
86
  feeMonitors.start()
87
+ apyRatesMonitor.start()
86
88
 
87
89
  await assetsModule.load()
88
90
  await connectedOrigins.load()
@@ -1,4 +1,6 @@
1
+ import autoEnableAssetsPlugin from '@exodus/auto-enable-assets-plugin'
2
+
1
3
  import logLifecyclePlugin from './log-lifecycle'
2
4
  import restorePlugin from './restore'
3
5
 
4
- export default [logLifecyclePlugin, restorePlugin]
6
+ export default [logLifecyclePlugin, restorePlugin, autoEnableAssetsPlugin]