@sonarwatch/portfolio-plugins 0.14.128 → 0.14.129

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.
Files changed (190) hide show
  1. package/CHANGELOG.md +2124 -2120
  2. package/README.md +3 -3
  3. package/package.json +1 -1
  4. package/src/index.js +5 -0
  5. package/src/index.js.map +1 -1
  6. package/src/plugins/adrena/positionsFetcher.js +1 -0
  7. package/src/plugins/adrena/positionsFetcher.js.map +1 -1
  8. package/src/plugins/allbridge/positionsFetcher.js +9 -1
  9. package/src/plugins/allbridge/positionsFetcher.js.map +1 -1
  10. package/src/plugins/armada-staking/stakingFetcher.js +4 -1
  11. package/src/plugins/armada-staking/stakingFetcher.js.map +1 -1
  12. package/src/plugins/aurory/stakingFetcher.js +5 -1
  13. package/src/plugins/aurory/stakingFetcher.js.map +1 -1
  14. package/src/plugins/balancer/helpers/pools.js +21 -21
  15. package/src/plugins/bonfida/offersFetcher.js +30 -37
  16. package/src/plugins/bonfida/offersFetcher.js.map +1 -1
  17. package/src/plugins/bonkrewards/positionFetcher.js +16 -22
  18. package/src/plugins/bonkrewards/positionFetcher.js.map +1 -1
  19. package/src/plugins/cyberfrogs/thorDepositFetcher.js +2 -0
  20. package/src/plugins/cyberfrogs/thorDepositFetcher.js.map +1 -1
  21. package/src/plugins/daos/realmsDepositsFetcher.js +29 -43
  22. package/src/plugins/daos/realmsDepositsFetcher.js.map +1 -1
  23. package/src/plugins/debridge/dlmmVaultsFetcher.js +16 -10
  24. package/src/plugins/debridge/dlmmVaultsFetcher.js.map +1 -1
  25. package/src/plugins/defiland/stakingFetcher.js +8 -1
  26. package/src/plugins/defiland/stakingFetcher.js.map +1 -1
  27. package/src/plugins/defituna/lendingFetcher.js +3 -0
  28. package/src/plugins/defituna/lendingFetcher.js.map +1 -1
  29. package/src/plugins/defituna/positionsFetcher.js +7 -1
  30. package/src/plugins/defituna/positionsFetcher.js.map +1 -1
  31. package/src/plugins/defituna/structs.d.ts +1 -0
  32. package/src/plugins/defituna/structs.js.map +1 -1
  33. package/src/plugins/divvy/constants.d.ts +1 -0
  34. package/src/plugins/divvy/constants.js +2 -1
  35. package/src/plugins/divvy/constants.js.map +1 -1
  36. package/src/plugins/divvy/housePoolFetcher.js +3 -0
  37. package/src/plugins/divvy/housePoolFetcher.js.map +1 -1
  38. package/src/plugins/divvy/stakingFetcher.js +3 -1
  39. package/src/plugins/divvy/stakingFetcher.js.map +1 -1
  40. package/src/plugins/drift/depositsFetcher.js +15 -0
  41. package/src/plugins/drift/depositsFetcher.js.map +1 -1
  42. package/src/plugins/drift-market-maker-vault/depositsFetcher.js +2 -1
  43. package/src/plugins/drift-market-maker-vault/depositsFetcher.js.map +1 -1
  44. package/src/plugins/elemental/depositFetcher.js +3 -0
  45. package/src/plugins/elemental/depositFetcher.js.map +1 -1
  46. package/src/plugins/ensofi/solanaLoansFetcher.js +6 -0
  47. package/src/plugins/ensofi/solanaLoansFetcher.js.map +1 -1
  48. package/src/plugins/exponent/liquidityFetcher.js +1 -0
  49. package/src/plugins/exponent/liquidityFetcher.js.map +1 -1
  50. package/src/plugins/exponent/tradeFetcher.js +1 -0
  51. package/src/plugins/exponent/tradeFetcher.js.map +1 -1
  52. package/src/plugins/famousfoxfederation/stakingFetcher.js +18 -22
  53. package/src/plugins/famousfoxfederation/stakingFetcher.js.map +1 -1
  54. package/src/plugins/flash/perpetualFetcher.js +1 -1
  55. package/src/plugins/flash/perpetualFetcher.js.map +1 -1
  56. package/src/plugins/fragmetric/pricingJob.js +6 -0
  57. package/src/plugins/fragmetric/pricingJob.js.map +1 -1
  58. package/src/plugins/francium/lendingFetcher.js +1 -0
  59. package/src/plugins/francium/lendingFetcher.js.map +1 -1
  60. package/src/plugins/futarchy/daosJob.js +9 -0
  61. package/src/plugins/futarchy/daosJob.js.map +1 -1
  62. package/src/plugins/genesysgo/stakingFetcher.js +12 -25
  63. package/src/plugins/genesysgo/stakingFetcher.js.map +1 -1
  64. package/src/plugins/goosefx/stakingFetcher.js +18 -27
  65. package/src/plugins/goosefx/stakingFetcher.js.map +1 -1
  66. package/src/plugins/gpool/stakingFetcher.js +5 -1
  67. package/src/plugins/gpool/stakingFetcher.js.map +1 -1
  68. package/src/plugins/guano/constants.d.ts +8 -0
  69. package/src/plugins/guano/constants.js +15 -0
  70. package/src/plugins/guano/constants.js.map +1 -0
  71. package/src/plugins/guano/filters.d.ts +20 -0
  72. package/src/plugins/guano/filters.js +41 -0
  73. package/src/plugins/guano/filters.js.map +1 -0
  74. package/src/plugins/guano/index.d.ts +6 -0
  75. package/src/plugins/guano/index.js +10 -0
  76. package/src/plugins/guano/index.js.map +1 -0
  77. package/src/plugins/guano/stakingFetcher.d.ts +3 -0
  78. package/src/plugins/guano/stakingFetcher.js +70 -0
  79. package/src/plugins/guano/stakingFetcher.js.map +1 -0
  80. package/src/plugins/guano/structs.d.ts +34 -0
  81. package/src/plugins/guano/structs.js +33 -0
  82. package/src/plugins/guano/structs.js.map +1 -0
  83. package/src/plugins/guano/types.d.ts +15 -0
  84. package/src/plugins/guano/types.js +3 -0
  85. package/src/plugins/guano/types.js.map +1 -0
  86. package/src/plugins/hedgehog/ammJob.js +8 -0
  87. package/src/plugins/hedgehog/ammJob.js.map +1 -1
  88. package/src/plugins/hxro/stakingFetcher.js +2 -0
  89. package/src/plugins/hxro/stakingFetcher.js.map +1 -1
  90. package/src/plugins/iloop/depositsFetcher.js +8 -0
  91. package/src/plugins/iloop/depositsFetcher.js.map +1 -1
  92. package/src/plugins/jupiter/exchange/dcaFetcher.js +5 -1
  93. package/src/plugins/jupiter/exchange/dcaFetcher.js.map +1 -1
  94. package/src/plugins/jupiter/exchange/limitFetcher.js +2 -0
  95. package/src/plugins/jupiter/exchange/limitFetcher.js.map +1 -1
  96. package/src/plugins/jupiter/exchange/valueAverageFetcher.js +1 -0
  97. package/src/plugins/jupiter/exchange/valueAverageFetcher.js.map +1 -1
  98. package/src/plugins/kamino/lendsFetcher.js +6 -0
  99. package/src/plugins/kamino/lendsFetcher.js.map +1 -1
  100. package/src/plugins/kamino/ordersFetcher.js +2 -1
  101. package/src/plugins/kamino/ordersFetcher.js.map +1 -1
  102. package/src/plugins/layer3/stakingFetcher.js +1 -0
  103. package/src/plugins/layer3/stakingFetcher.js.map +1 -1
  104. package/src/plugins/lifinity/lockerFetcher.js +14 -17
  105. package/src/plugins/lifinity/lockerFetcher.js.map +1 -1
  106. package/src/plugins/loverflow/airdropClaimFetcher.js +1 -0
  107. package/src/plugins/loverflow/airdropClaimFetcher.js.map +1 -1
  108. package/src/plugins/magiceden/escrowFetcher.js +12 -18
  109. package/src/plugins/magiceden/escrowFetcher.js.map +1 -1
  110. package/src/plugins/marginfi/helpers.d.ts +2 -1
  111. package/src/plugins/marginfi/helpers.js +8 -2
  112. package/src/plugins/marginfi/helpers.js.map +1 -1
  113. package/src/plugins/marinade/ticketsFetcher.js +14 -31
  114. package/src/plugins/marinade/ticketsFetcher.js.map +1 -1
  115. package/src/plugins/metaplex/resizableNftFetcher.js +1 -0
  116. package/src/plugins/metaplex/resizableNftFetcher.js.map +1 -1
  117. package/src/plugins/nxfinance/positionsFetcher.js +19 -2
  118. package/src/plugins/nxfinance/positionsFetcher.js.map +1 -1
  119. package/src/plugins/orca/getWhirlpoolPositions.js +10 -1
  120. package/src/plugins/orca/getWhirlpoolPositions.js.map +1 -1
  121. package/src/plugins/parcl/depositsFetcher.js +1 -1
  122. package/src/plugins/parcl/depositsFetcher.js.map +1 -1
  123. package/src/plugins/parcl/marginFetcher.js +1 -1
  124. package/src/plugins/parcl/marginFetcher.js.map +1 -1
  125. package/src/plugins/parcl/stakingFetcher.js +6 -3
  126. package/src/plugins/parcl/stakingFetcher.js.map +1 -1
  127. package/src/plugins/photofinish/stakingFetcher.js +6 -1
  128. package/src/plugins/photofinish/stakingFetcher.js.map +1 -1
  129. package/src/plugins/picasso/unstakingPositionsFetcher.js +3 -2
  130. package/src/plugins/picasso/unstakingPositionsFetcher.js.map +1 -1
  131. package/src/plugins/quarry/calculatePositions.js +7 -1
  132. package/src/plugins/quarry/calculatePositions.js.map +1 -1
  133. package/src/plugins/quarry/positionsFetcher.js +2 -0
  134. package/src/plugins/quarry/positionsFetcher.js.map +1 -1
  135. package/src/plugins/quarry/types.d.ts +3 -0
  136. package/src/plugins/ratex/positionsFetcher.js +2 -0
  137. package/src/plugins/ratex/positionsFetcher.js.map +1 -1
  138. package/src/plugins/saber/lpTokensJob.js +1 -0
  139. package/src/plugins/saber/lpTokensJob.js.map +1 -1
  140. package/src/plugins/sandglass/depositFetcher.js +3 -0
  141. package/src/plugins/sandglass/depositFetcher.js.map +1 -1
  142. package/src/plugins/sharky/loansFetcher.js +1 -0
  143. package/src/plugins/sharky/loansFetcher.js.map +1 -1
  144. package/src/plugins/solayer/airdropFetcher.d.ts +3 -0
  145. package/src/plugins/solayer/airdropFetcher.js +55 -0
  146. package/src/plugins/solayer/airdropFetcher.js.map +1 -0
  147. package/src/plugins/solayer/constants.d.ts +5 -0
  148. package/src/plugins/solayer/constants.js +13 -1
  149. package/src/plugins/solayer/constants.js.map +1 -1
  150. package/src/plugins/solayer/index.d.ts +2 -0
  151. package/src/plugins/solayer/index.js +4 -2
  152. package/src/plugins/solayer/index.js.map +1 -1
  153. package/src/plugins/solayer/proofsFetcher.js +7 -6
  154. package/src/plugins/solayer/proofsFetcher.js.map +1 -1
  155. package/src/plugins/solayer/types.d.ts +8 -0
  156. package/src/plugins/solayer/types.js +3 -0
  157. package/src/plugins/solayer/types.js.map +1 -0
  158. package/src/plugins/spdr/stakingFetcher.js +3 -0
  159. package/src/plugins/spdr/stakingFetcher.js.map +1 -1
  160. package/src/plugins/stabble/poolsJob.js +1 -0
  161. package/src/plugins/stabble/poolsJob.js.map +1 -1
  162. package/src/plugins/staratlas/lockersFetcher.js +2 -0
  163. package/src/plugins/staratlas/lockersFetcher.js.map +1 -1
  164. package/src/plugins/staratlas/stakingFetcher.js +2 -1
  165. package/src/plugins/staratlas/stakingFetcher.js.map +1 -1
  166. package/src/plugins/streamflow/vestingFetcher.js +1 -1
  167. package/src/plugins/streamflow/vestingFetcher.js.map +1 -1
  168. package/src/plugins/sushiswap/helpers.js +24 -24
  169. package/src/plugins/tensor/bidsFetcher.js +1 -1
  170. package/src/plugins/tensor/bidsFetcher.js.map +1 -1
  171. package/src/plugins/texture/loansFetcher.js +2 -1
  172. package/src/plugins/texture/loansFetcher.js.map +1 -1
  173. package/src/plugins/tulip/depositsFetcher.js +3 -1
  174. package/src/plugins/tulip/depositsFetcher.js.map +1 -1
  175. package/src/plugins/uniswap-v2/helpers.js +22 -22
  176. package/src/plugins/uxd/stakingFetcher.js +4 -3
  177. package/src/plugins/uxd/stakingFetcher.js.map +1 -1
  178. package/src/plugins/vaultka/lendingFetcher.js +5 -0
  179. package/src/plugins/vaultka/lendingFetcher.js.map +1 -1
  180. package/src/plugins/vaultka/strategyFetcher.js +3 -0
  181. package/src/plugins/vaultka/strategyFetcher.js.map +1 -1
  182. package/src/plugins/whalesmarket/depositFetcher.js +7 -5
  183. package/src/plugins/whalesmarket/depositFetcher.js.map +1 -1
  184. package/src/plugins/zelo/positionsFetcher.js +2 -0
  185. package/src/plugins/zelo/positionsFetcher.js.map +1 -1
  186. package/src/plugins/zeta/airdropFetcher.js +14 -14
  187. package/src/plugins/zeta/depositsFetcher.js +5 -1
  188. package/src/plugins/zeta/depositsFetcher.js.map +1 -1
  189. package/src/utils/sei/constants.js +8 -8
  190. package/src/utils/sei/getQueryBalanceByOwner.js +4 -4
@@ -8,35 +8,29 @@ var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, ge
8
8
  step((generator = generator.apply(thisArg, _arguments || [])).next());
9
9
  });
10
10
  };
11
- var __importDefault = (this && this.__importDefault) || function (mod) {
12
- return (mod && mod.__esModule) ? mod : { "default": mod };
13
- };
14
11
  Object.defineProperty(exports, "__esModule", { value: true });
15
12
  const portfolio_core_1 = require("@sonarwatch/portfolio-core");
16
- const bignumber_js_1 = __importDefault(require("bignumber.js"));
17
13
  const constants_1 = require("./constants");
18
14
  const helpers_1 = require("./helpers");
19
15
  const clients_1 = require("../../utils/clients");
20
- const tokenPriceToAssetToken_1 = __importDefault(require("../../utils/misc/tokenPriceToAssetToken"));
16
+ const ElementRegistry_1 = require("../../utils/elementbuilder/ElementRegistry");
21
17
  const executor = (owner, cache) => __awaiter(void 0, void 0, void 0, function* () {
22
18
  const pda = (0, helpers_1.getEscrowAccount)(owner);
23
19
  const client = (0, clients_1.getClientSolana)();
24
20
  const amount = yield client.getBalance(pda);
25
21
  if (!amount)
26
22
  return [];
27
- const solTokenPrice = yield cache.getTokenPrice(portfolio_core_1.solanaNativeAddress, portfolio_core_1.NetworkId.solana);
28
- const asset = (0, tokenPriceToAssetToken_1.default)(portfolio_core_1.solanaNativeAddress, new bignumber_js_1.default(amount).dividedBy(Math.pow(10, portfolio_core_1.solanaNativeDecimals)).toNumber(), portfolio_core_1.NetworkId.solana, solTokenPrice);
29
- return [
30
- {
31
- type: portfolio_core_1.PortfolioElementType.multiple,
32
- label: 'Deposit',
33
- networkId: portfolio_core_1.NetworkId.solana,
34
- platformId: constants_1.platformId,
35
- name: 'Escrow',
36
- value: asset.value,
37
- data: { assets: [asset] },
38
- },
39
- ];
23
+ const registry = new ElementRegistry_1.ElementRegistry(portfolio_core_1.NetworkId.solana, constants_1.platformId);
24
+ const element = registry.addElementMultiple({
25
+ label: 'Deposit',
26
+ ref: pda,
27
+ name: 'Escrow',
28
+ });
29
+ element.addAsset({
30
+ address: portfolio_core_1.solanaNativeAddress,
31
+ amount,
32
+ });
33
+ return registry.getElements(cache);
40
34
  });
41
35
  const fetcher = {
42
36
  id: `${constants_1.platformId}-escrow`,
@@ -1 +1 @@
1
- {"version":3,"file":"escrowFetcher.js","sourceRoot":"","sources":["../../../../../../packages/plugins/src/plugins/magiceden/escrowFetcher.ts"],"names":[],"mappings":";;;;;;;;;;;;;;AAAA,+DAKoC;AACpC,gEAAqC;AAGrC,2CAAyC;AACzC,uCAA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;AAG5E,2CAAyC;AACzC,uCAA6C;AAC7C,iDAAsD;AACtD,gFAA6E;AAE7E,MAAM,QAAQ,GAAoB,CAAO,KAAa,EAAE,KAAY,EAAE,EAAE;IACtE,MAAM,GAAG,GAAG,IAAA,0BAAgB,EAAC,KAAK,CAAC,CAAC;IACpC,MAAM,MAAM,GAAG,IAAA,yBAAe,GAAE,CAAC;IAEjC,MAAM,MAAM,GAAG,MAAM,MAAM,CAAC,UAAU,CAAC,GAAG,CAAC,CAAC;IAC5C,IAAI,CAAC,MAAM;QAAE,OAAO,EAAE,CAAC;IAEvB,MAAM,QAAQ,GAAG,IAAI,iCAAe,CAAC,0BAAS,CAAC,MAAM,EAAE,sBAAU,CAAC,CAAC;IACnE,MAAM,OAAO,GAAG,QAAQ,CAAC,kBAAkB,CAAC;QAC1C,KAAK,EAAE,SAAS;QAChB,GAAG,EAAE,GAAG;QACR,IAAI,EAAE,QAAQ;KACf,CAAC,CAAC;IACH,OAAO,CAAC,QAAQ,CAAC;QACf,OAAO,EAAE,oCAAmB;QAC5B,MAAM;KACP,CAAC,CAAC;IAEH,OAAO,QAAQ,CAAC,WAAW,CAAC,KAAK,CAAC,CAAC;AACrC,CAAC,CAAA,CAAC;AAEF,MAAM,OAAO,GAAY;IACvB,EAAE,EAAE,GAAG,sBAAU,SAAS;IAC1B,SAAS,EAAE,0BAAS,CAAC,MAAM;IAC3B,QAAQ;CACT,CAAC;AAEF,kBAAe,OAAO,CAAC"}
@@ -3,6 +3,7 @@ import { PortfolioElement, TokenPrice } from '@sonarwatch/portfolio-core';
3
3
  import { Bank } from './structs/Bank';
4
4
  import { MarginfiAccount } from './structs/MarginfiAccount';
5
5
  import { BankInfo } from './types';
6
+ import { ParsedAccount } from '../../utils/solana';
6
7
  export declare function wrappedI80F48toBigNumber({ value }: {
7
8
  value: BigNumber;
8
9
  }, scaleDecimal?: number): BigNumber;
@@ -10,4 +11,4 @@ export declare function computeInterestRates(bank: Bank): {
10
11
  lendingApr: number;
11
12
  borrowingApr: number;
12
13
  };
13
- export declare function getElementFromAccount(marginfiAccount: MarginfiAccount, banksInfoByAddress: Map<string, BankInfo>, tokenPriceById: Map<string, TokenPrice>): PortfolioElement | null;
14
+ export declare function getElementFromAccount(marginfiAccount: ParsedAccount<MarginfiAccount>, banksInfoByAddress: Map<string, BankInfo>, tokenPriceById: Map<string, TokenPrice>): PortfolioElement | null;
@@ -89,7 +89,9 @@ function getElementFromAccount(marginfiAccount, banksInfoByAddress, tokenPriceBy
89
89
  // If one of the deposited asset is a stake collateral, show it inside the element name
90
90
  if ((tokenPrice === null || tokenPrice === void 0 ? void 0 : tokenPrice.elementName) === 'Stake Collateral')
91
91
  name = 'Stake Collateral';
92
- suppliedAssets.push((0, tokenPriceToAssetToken_1.default)(bankInfo.mint.toString(), suppliedAmount, portfolio_core_1.NetworkId.solana, tokenPrice));
92
+ suppliedAssets.push(Object.assign(Object.assign({}, (0, tokenPriceToAssetToken_1.default)(bankInfo.mint.toString(), suppliedAmount, portfolio_core_1.NetworkId.solana, tokenPrice)), { sourceRefs: [
93
+ { name: 'Lending Market', address: balance.bankPk.toString() },
94
+ ] }));
93
95
  suppliedYields.push(bankInfo.suppliedYields);
94
96
  }
95
97
  if (!balance.liabilityShares.value.isZero()) {
@@ -97,7 +99,9 @@ function getElementFromAccount(marginfiAccount, banksInfoByAddress, tokenPriceBy
97
99
  const borrowedAmount = wrappedI80F48toBigNumber(balance.liabilityShares)
98
100
  .times(bankInfo.dividedLiabilityShareValue)
99
101
  .toNumber();
100
- borrowedAssets.push((0, tokenPriceToAssetToken_1.default)(bankInfo.mint.toString(), borrowedAmount, portfolio_core_1.NetworkId.solana, tokenPrice));
102
+ borrowedAssets.push(Object.assign(Object.assign({}, (0, tokenPriceToAssetToken_1.default)(bankInfo.mint.toString(), borrowedAmount, portfolio_core_1.NetworkId.solana, tokenPrice)), { sourceRefs: [
103
+ { name: 'Lending Market', address: balance.bankPk.toString() },
104
+ ] }));
101
105
  borrowedYields.push(bankInfo.borrowedYields);
102
106
  }
103
107
  }
@@ -127,6 +131,8 @@ function getElementFromAccount(marginfiAccount, banksInfoByAddress, tokenPriceBy
127
131
  rewardAssets,
128
132
  rewardValue,
129
133
  value,
134
+ ref: marginfiAccount.pubkey.toString(),
135
+ link: 'https://app.marginfi.com/portfolio',
130
136
  },
131
137
  name,
132
138
  };
@@ -1 +1 @@
1
- {"version":3,"file":"helpers.js","sourceRoot":"","sources":["../../../../../../packages/plugins/src/plugins/marginfi/helpers.ts"],"names":[],"mappings":";;;;;;AAAA,gEAAqC;AACrC,4DAAiC;AACjC,+DAQoC;AAIpC,qGAA6E;AAC7E,2CAAyC;AAEzC,SAAgB,wBAAwB,CACtC,EAAE,KAAK,EAAwB,EAC/B,YAAY,GAAG,CAAC;IAEhB,IAAI,CAAC,KAAK;QAAE,OAAO,IAAI,sBAAS,CAAC,CAAC,CAAC,CAAC;IAEpC,MAAM,OAAO,GAAG,IAAI,oBAAO,CACzB,GAAG,KAAK,CAAC,UAAU,EAAE,CAAC,CAAC,CAAC,GAAG,CAAC,CAAC,CAAC,EAAE,KAAK,KAAK,CAAC,GAAG,EAAE,CAAC,QAAQ,CAAC,CAAC,CAAC,MAAM,CACnE,CAAC,SAAS,CAAC,SAAA,EAAE,EAAI,YAAY,CAAA,CAAC,CAAC;IAChC,OAAO,IAAI,sBAAS,CAAC,OAAO,CAAC,QAAQ,EAAE,CAAC,CAAC;AAC3C,CAAC;AAVD,4DAUC;AAED,SAAS,yBAAyB,CAAC,IAAU;IAC3C,OAAO,wBAAwB,CAAC,IAAI,CAAC,oBAAoB,CAAC,CAAC,KAAK,CAC9D,wBAAwB,CAAC,IAAI,CAAC,mBAAmB,CAAC,CACnD,CAAC;AACJ,CAAC;AACD,SAAS,qBAAqB,CAAC,IAAU;IACvC,OAAO,wBAAwB,CAAC,IAAI,CAAC,gBAAgB,CAAC,CAAC,KAAK,CAC1D,wBAAwB,CAAC,IAAI,CAAC,eAAe,CAAC,CAC/C,CAAC;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AAI,CAAC,QAAQ,CAAC,cAAc,CAAC,CAAC;YAC9C,MAAM,cAAc,GAAG,wBAAwB,CAAC,OAAO,CAAC,eAAe,CAAC;iBACrE,KAAK,CAAC,QAAQ,CAAC,0BAA0B,CAAC;iBAC1C,QAAQ,EAAE,CAAC;YAEd,cAAc,CAAC,IAAI,CACjB,IAAA,gCAAsB,EACpB,QAAQ,CAAC,IAAI,CAAC,QAAQ,EAAE,EACxB,cAAc,EACd,0BAAS,CAAC,MAAM,EAChB,UAAU,CACX,CACF,CAAC;YACF,cAAc,CAAC,IAAI,CAAC,QAAQ,CAAC,cAAc,CAAC,CAAC;QAC/C,CAAC;IACH,CAAC;IAED,IAAI,cAAc,CAAC,MAAM,KAAK,CAAC,IAAI,cAAc,CAAC,MAAM,KAAK,CAAC;QAAE,OAAO,IAAI,CAAC;IAE5E,MAAM,EAAE,aAAa,EAAE,WAAW,EAAE,aAAa,EAAE,KAAK,EAAE,WAAW,EAAE,GACrE,IAAA,wCAAuB,EAAC;QACtB,cAAc;QACd,cAAc;QACd,YAAY;QACZ,YAAY;QACZ,eAAe;KAChB,CAAC,CAAC;IAEL,OAAO;QACL,IAAI,EAAE,qCAAoB,CAAC,UAAU;QACrC,SAAS,EAAE,0BAAS,CAAC,MAAM;QAC3B,UAAU,EAAV,sBAAU;QACV,KAAK,EAAE,SAAS;QAChB,KAAK;QACL,IAAI,EAAE;YACJ,cAAc;YACd,aAAa;YACb,cAAc;YACd,cAAc;YACd,aAAa;YACb,cAAc;YACd,WAAW;YACX,YAAY;YACZ,WAAW;YACX,KAAK;SACN;QACD,IAAI;KACL,CAAC;AACJ,CAAC;AA/FD,sDA+FC"}
1
+ {"version":3,"file":"helpers.js","sourceRoot":"","sources":["../../../../../../packages/plugins/src/plugins/marginfi/helpers.ts"],"names":[],"mappings":";;;;;;AAAA,gEAAqC;AACrC,4DAAiC;AACjC,+DAQoC;AAIpC,qGAA6E;AAC7E,2CAAyC;AAGzC,SAAgB,wBAAwB,CACtC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U,CACX,KACD,UAAU,EAAE;oBACV,EAAE,IAAI,EAAE,gBAAgB,EAAE,OAAO,EAAE,OAAO,CAAC,MAAM,CAAC,QAAQ,EAAE,EAAE;iBAC/D,IACD,CAAC;YACH,cAAc,CAAC,IAAI,CAAC,QAAQ,CAAC,cAAc,CAAC,CAAC;QAC/C,CAAC;IACH,CAAC;IAED,IAAI,cAAc,CAAC,MAAM,KAAK,CAAC,IAAI,cAAc,CAAC,MAAM,KAAK,CAAC;QAAE,OAAO,IAAI,CAAC;IAE5E,MAAM,EAAE,aAAa,EAAE,WAAW,EAAE,aAAa,EAAE,KAAK,EAAE,WAAW,EAAE,GACrE,IAAA,wCAAuB,EAAC;QACtB,cAAc;QACd,cAAc;QACd,YAAY;QACZ,YAAY;QACZ,eAAe;KAChB,CAAC,CAAC;IAEL,OAAO;QACL,IAAI,EAAE,qCAAoB,CAAC,UAAU;QACrC,SAAS,EAAE,0BAAS,CAAC,MAAM;QAC3B,UAAU,EAAV,sBAAU;QACV,KAAK,EAAE,SAAS;QAChB,KAAK;QACL,IAAI,EAAE;YACJ,cAAc;YACd,aAAa;YACb,cAAc;YACd,cAAc;YACd,aAAa;YACb,cAAc;YACd,WAAW;YACX,YAAY;YACZ,WAAW;YACX,KAAK;YACL,GAAG,EAAE,eAAe,CAAC,MAAM,CAAC,QAAQ,EAAE;YACtC,IAAI,EAAE,oCAAoC;SAC3C;QACD,IAAI;KACL,CAAC;AACJ,CAAC;AAvGD,sDAuGC"}
@@ -15,44 +15,27 @@ const constants_1 = require("./constants");
15
15
  const structs_1 = require("./structs");
16
16
  const filters_1 = require("./filters");
17
17
  const clients_1 = require("../../utils/clients");
18
+ const ElementRegistry_1 = require("../../utils/elementbuilder/ElementRegistry");
18
19
  const executor = (owner, cache) => __awaiter(void 0, void 0, void 0, function* () {
19
20
  const connection = (0, clients_1.getClientSolana)();
20
21
  const tickets = yield (0, solana_1.getParsedProgramAccounts)(connection, structs_1.ticketStruct, constants_1.marinadeTicketProgramId, (0, filters_1.ticketFilters)(owner));
21
22
  if (tickets.length === 0)
22
23
  return [];
23
- const assets = [];
24
+ const registry = new ElementRegistry_1.ElementRegistry(portfolio_core_1.NetworkId.solana, constants_1.platformId);
25
+ const element = registry.addElementMultiple({
26
+ label: 'Rewards',
27
+ name: 'Tickets',
28
+ link: 'https://marinade.finance/',
29
+ });
24
30
  for (let i = 0; i < tickets.length; i += 1) {
25
- const ticket = tickets[i];
26
- const amount = ticket.lamportsAmount.div(constants_1.solFactor).toNumber();
27
- const tokenPrice = yield cache.getTokenPrice(portfolio_core_1.solanaNativeAddress, portfolio_core_1.NetworkId.solana);
28
- const price = tokenPrice ? tokenPrice.price : null;
29
- const value = price ? price * amount : null;
30
- const asset = {
31
- type: portfolio_core_1.PortfolioAssetType.token,
32
- networkId: portfolio_core_1.NetworkId.solana,
33
- value,
34
- attributes: {},
35
- data: {
36
- address: portfolio_core_1.solanaNativeAddress,
37
- price,
38
- amount,
39
- },
40
- };
41
- assets.push(asset);
31
+ element.addAsset({
32
+ address: portfolio_core_1.solanaNativeAddress,
33
+ amount: tickets[i].lamportsAmount.div(constants_1.solFactor).toNumber(),
34
+ alreadyShifted: true,
35
+ ref: tickets[i].pubkey,
36
+ });
42
37
  }
43
- if (assets.length === 0)
44
- return [];
45
- const element = {
46
- type: portfolio_core_1.PortfolioElementType.multiple,
47
- networkId: portfolio_core_1.NetworkId.solana,
48
- platformId: constants_1.platformId,
49
- label: 'Rewards',
50
- value: (0, portfolio_core_1.getUsdValueSumStrict)(assets.map((a) => a.value)),
51
- data: {
52
- assets,
53
- },
54
- };
55
- return [element];
38
+ return registry.getElements(cache);
56
39
  });
57
40
  const fetcher = {
58
41
  id: `${constants_1.platformId}-tickets`,
@@ -1 +1 @@
1
- {"version":3,"file":"ticketsFetcher.js","sourceRoot":"","sources":["../../../../../../packages/plugins/src/plugins/marinade/ticketsFetcher.ts"],"names":[],"mappings":";;;;;;;;;;;AAAA,+DASoC;AACpC,+CAA8D;AAC9D,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;IACrB,CAAC;IACD,IAAI,MAAM,CAAC,MAAM,KAAK,CAAC;QAAE,OAAO,EAAE,CAAC;IAEnC,MAAM,OAAO,GAA6B;QACxC,IAAI,EAAE,qCAAoB,CAAC,QAAQ;QACnC,SAAS,EAAE,0BAAS,CAAC,MAAM;QAC3B,UAAU,EAAV,sBAAU;QACV,KAAK,EAAE,SAAS;QAChB,KAAK,EAAE,IAAA,qCAAoB,EAAC,MAAM,CAAC,GAAG,CAAC,CAAC,CAAC,EAAE,EAAE,CAAC,CAAC,CAAC,KAAK,CAAC,CAAC;QACvD,IAAI,EAAE;YACJ,MAAM;SACP;KACF,CAAC;IACF,OAAO,CAAC,OAAO,CAAC,CAAC;AACnB,CAAC,CAAA,CAAC;AAEF,MAAM,OAAO,GAAY;IACvB,EAAE,EAAE,GAAG,sBAAU,UAAU;IAC3B,SAAS,EAAE,0BAAS,CAAC,MAAM;IAC3B,QAAQ;CACT,CAAC;AAEF,kBAAe,OAAO,CAAC"}
1
+ {"version":3,"file":"ticketsFetcher.js","sourceRoot":"","sources":["../../../../../../packages/plugins/src/plugins/marinade/ticketsFetcher.ts"],"names":[],"mappings":";;;;;;;;;;;AAAA,+DAA4E;AAC5E,+CAA8D;AAC9D,2CAA6E;AAC7E,uCAAyC;AACzC,uCAA0C;AAC1C,iDAAsD;AAGtD,gFAA6E;AAE7E,MAAM,QAAQ,GAAoB,CAAO,KAAa,EAAE,KAAY,EAAE,EAAE;IACtE,MAAM,UAAU,GAAG,IAAA,yBAAe,GAAE,CAAC;IACrC,MAAM,OAAO,GAAG,MAAM,IAAA,iCAAwB,EAC5C,UAAU,EACV,sBAAY,EACZ,mCAAuB,EACvB,IAAA,uBAAa,EAAC,KAAK,CAAC,CACrB,CAAC;IACF,IAAI,OAAO,CAAC,MAAM,KAAK,CAAC;QAAE,OAAO,EAAE,CAAC;IAEpC,MAAM,QAAQ,GAAG,IAAI,iCAAe,CAAC,0BAAS,CAAC,MAAM,EAAE,sBAAU,CAAC,CAAC;IACnE,MAAM,OAAO,GAAG,QAAQ,CAAC,kBAAkB,CAAC;QAC1C,KAAK,EAAE,SAAS;QAChB,IAAI,EAAE,SAAS;QACf,IAAI,EAAE,2BAA2B;KAClC,CAAC,CAAC;IAEH,KAAK,IAAI,CAAC,GAAG,CAAC,EAAE,CAAC,GAAG,OAAO,CAAC,MAAM,EAAE,CAAC,IAAI,CAAC,EAAE,CAAC;QAC3C,OAAO,CAAC,QAAQ,CAAC;YACf,OAAO,EAAE,oCAAmB;YAC5B,MAAM,EAAE,OAAO,CAAC,CAAC,CAAC,CAAC,cAAc,CAAC,GAAG,CAAC,qBAAS,CAAC,CAAC,QAAQ,EAAE;YAC3D,cAAc,EAAE,IAAI;YACpB,GAAG,EAAE,OAAO,CAAC,CAAC,CAAC,CAAC,MAAM;SACvB,CAAC,CAAC;IACL,CAAC;IAED,OAAO,QAAQ,CAAC,WAAW,CAAC,KAAK,CAAC,CAAC;AACrC,CAAC,CAAA,CAAC;AAEF,MAAM,OAAO,GAAY;IACvB,EAAE,EAAE,GAAG,sBAAU,UAAU;IAC3B,SAAS,EAAE,0BAAS,CAAC,MAAM;IAC3B,QAAQ;CACT,CAAC;AAEF,kBAAe,OAAO,CAAC"}
@@ -57,6 +57,7 @@ const executor = (owner, cache) => __awaiter(void 0, void 0, void 0, function* (
57
57
  const element = elementRegistry.addElementMultiple({
58
58
  label: 'Rewards',
59
59
  name: 'Resize Program',
60
+ link: 'https://resize.metaplex.com',
60
61
  });
61
62
  element.addAsset({
62
63
  address: portfolio_core_1.solanaNativeAddress,
@@ -1 +1 @@
1
- {"version":3,"file":"resizableNftFetcher.js","sourceRoot":"","sources":["../../../../../../packages/plugins/src/plugins/metaplex/resizableNftFetcher.ts"],"names":[],"mappings":";;;;;;;;;;;AAAA,+DAA4E;AAC5E,6CAA4C;AAE5C,2CAIqB;AAErB,gFAA6E;AAC7E,iDAAsD;AACtD,+CAAwE;AACxE,uCAAqE;AACrE,gGAA6F;AAE7F,MAAM,QA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AC;QACjD,IAAI,CAAC,gBAAgB,CAAC,CAAC,CAAC;YAAE,SAAS;QAEnC,cAAc,GAAG,eAAe,CAAC,CAAC,CAAC,CAAC;QACpC,IAAI,CAAC,cAAc;YAAE,SAAS;QAE9B,IAAI,CAAA,MAAA,gBAAgB,CAAC,CAAC,CAAC,0CAAE,IAAI,CAAC,UAAU,MAAK,GAAG,EAAE,CAAC;YACjD,IAAI,cAAc,CAAC,IAAI,CAAC,UAAU,KAAK,GAAG,EAAE,CAAC;gBAC3C,MAAM,IAAI,kCAAsB,CAAC;YACnC,CAAC;YACD,IAAI,cAAc,CAAC,IAAI,CAAC,UAAU,KAAK,GAAG,EAAE,CAAC;gBAC3C,MAAM,IAAI,iCAAqB,CAAC;YAClC,CAAC;QACH,CAAC;IACH,CAAC;IAED,MAAM,eAAe,GAAG,IAAI,iCAAe,CAAC,0BAAS,CAAC,MAAM,EAAE,sBAAU,CAAC,CAAC;IAC1E,MAAM,OAAO,GAAG,eAAe,CAAC,kBAAkB,CAAC;QACjD,KAAK,EAAE,SAAS;QAChB,IAAI,EAAE,gBAAgB;KACvB,CAAC,CAAC;IAEH,OAAO,CAAC,QAAQ,CAAC;QACf,OAAO,EAAE,oCAAmB;QAC5B,MAAM;QACN,cAAc,EAAE,IAAI;QACpB,UAAU,EAAE;YACV,WAAW,EAAE,IAAI;SAClB;KACF,CAAC,CAAC;IAEH,OAAO,eAAe,CAAC,WAAW,CAAC,KAAK,CAAC,CAAC;AAC5C,CAAC,CAAA,CAAC;AAEF,MAAM,OAAO,GAAY;IACvB,EAAE,EAAE,GAAG,sBAAU,SAAS;IAC1B,SAAS,EAAE,0BAAS,CAAC,MAAM;IAC3B,QAAQ;CACT,CAAC;AAEF,kBAAe,OAAO,CAAC"}
1
+ {"version":3,"file":"resizableNftFetcher.js","sourceRoot":"","sources":["../../../../../../packages/plugins/src/plugins/metaplex/resizableNftFetcher.ts"],"names":[],"mappings":";;;;;;;;;;;AAAA,+DAA4E;AAC5E,6CA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7 +32,7 @@ const executor = (owner, cache) => __awaiter(void 0, void 0, void 0, function* (
32
32
  solayerPoolsMemo.getItem(cache),
33
33
  ]);
34
34
  if (!lendingPools)
35
- return [];
35
+ throw new Error('Lending pools missing in cache.');
36
36
  const [lendingAccounts, vSolPositionsAccounts, marginAccount, solayerUserAccounts,] = yield Promise.all([
37
37
  (0, helpers_1.getLendingAccounts)(lendingPools, owner), // JLP
38
38
  (0, helpers_1.getVSolPositionAccounts)(lendingPools, owner), // vSOL
@@ -76,9 +76,15 @@ const executor = (owner, cache) => __awaiter(void 0, void 0, void 0, function* (
76
76
  const element = elementRegistry.addElementLiquidity({
77
77
  label: 'Lending',
78
78
  name: 'GMS Lending Pool',
79
+ link: 'https://nxfinance.io/lend',
79
80
  });
80
81
  const formattedLendingPool = (0, helpers_1.formatLendingPool)(lendingPools[0], tokenPrice.decimals);
81
- const liquidity = element.addLiquidity({});
82
+ const liquidity = element.addLiquidity({
83
+ ref: lendingAccount.pubkey.toString(),
84
+ sourceRefs: [
85
+ { name: 'Lending Market', address: lendingPool.pubkey.toString() },
86
+ ],
87
+ });
82
88
  liquidity.addAsset({
83
89
  address: lendingPool.tokenMint,
84
90
  amount: new bignumber_js_1.default(lendingAccount.depositNotes).multipliedBy(formattedLendingPool.depositNoteRate),
@@ -111,6 +117,11 @@ const executor = (owner, cache) => __awaiter(void 0, void 0, void 0, function* (
111
117
  name: `vSOL Leverage x${new bignumber_js_1.default(position.leverageMultiples)
112
118
  .dividedBy(1000000)
113
119
  .decimalPlaces(2)}`,
120
+ link: 'https://nxfinance.io/leverage',
121
+ ref: vSolPositionsAccount.pubkey.toString(),
122
+ sourceRefs: [
123
+ { name: 'Lending Market', address: lendingPool.pubkey.toString() },
124
+ ],
114
125
  });
115
126
  const amount = new bignumber_js_1.default(new bignumber_js_1.default(position.leverageNote)
116
127
  .dividedBy(Math.pow(10, leverageTokenPrice.decimals))
@@ -131,12 +142,16 @@ const executor = (owner, cache) => __awaiter(void 0, void 0, void 0, function* (
131
142
  const elementMultiple = elementRegistry.addElementMultiple({
132
143
  label: 'Lending',
133
144
  name: 'Fulcrum Lending Pool',
145
+ link: 'https://nxfinance.io/lend',
146
+ ref: marginAccount.pubkey,
134
147
  });
135
148
  const elementBorrowlend = elementRegistry.addElementBorrowlend({
136
149
  label: 'Leverage',
137
150
  name: `JLP Leverage x${new bignumber_js_1.default(marginAccount.leverage)
138
151
  .dividedBy(100)
139
152
  .decimalPlaces(2)}`,
153
+ link: 'https://nxfinance.io/leverage',
154
+ ref: marginAccount.pubkey,
140
155
  });
141
156
  marginAccount.deposits.forEach((deposit) => {
142
157
  const marginPool = marginPools.find((mp) => (mp === null || mp === void 0 ? void 0 : mp.tokenMint) === deposit.tokenMint);
@@ -176,6 +191,8 @@ const executor = (owner, cache) => __awaiter(void 0, void 0, void 0, function* (
176
191
  return;
177
192
  const element = elementRegistry.addElementMultiple({
178
193
  label: 'Leverage',
194
+ link: 'https://nxfinance.io/leverage',
195
+ ref: solayerUserAccount.pubkey,
179
196
  });
180
197
  element.addAsset({
181
198
  address: solayerUserAccount.lrtMint,
@@ -1 +1 @@
1
- {"version":3,"file":"positionsFetcher.js","sourceRoot":"","sources":["../../../../../../packages/plugins/src/plugins/nxfinance/positionsFetcher.ts"],"names":[],"mappings":";;;;;;;;;;;;;;AAAA,+DAIoC;AACpC,gEAAqC;AAErC,2CAKqB;AAIrB,kEAA+D;AAC/D,uCASmB;AACnB,gFAA6E;AAE7E,MAAM,gBAAgB,GAAG,IAAI,6BAAa,CACxC,0BAAc,EACd;IACE,MAAM,EAAE,sBAAU;IAClB,SAAS,EAAE,0BAAS,CAAC,MAAM;CAC5B,CACF,CAAC;AACF,MAAM,gBAAgB,GAAG,IAAI,6BAAa,CACxC,0BAAc,EACd;IACE,MAAM,EAAE,sBAAU;IAClB,SAAS,EAAE,0BAAS,CAAC,MAAM;CAC5B,CACF,CAAC;AAEF,MAAM,QAAQ,GAAoB,CAAO,KAAa,EAAE,KAAY,EAAE,E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CAAA,CAAC;AAEF,MAAM,OAAO,GAAY;IACvB,EAAE,EAAE,GAAG,sBAAU,YAAY;IAC7B,SAAS,EAAE,0BAAS,CAAC,MAAM;IAC3B,QAAQ;CACT,CAAC;AAEF,kBAAe,OAAO,CAAC"}
1
+ {"version":3,"file":"positionsFetcher.js","sourceRoot":"","sources":["../../../../../../packages/plugins/src/plugins/nxfinance/positionsFetcher.ts"],"names":[],"mappings":";;;;;;;;;;;;;;AAAA,+DAIoC;AACpC,gEAAqC;AAErC,2CAKqB;AAIrB,kEAA+D;AAC/D,uCASmB;AACnB,gFAA6E;AAE7E,MAAM,gBAAgB,GAAG,IAAI,6BAAa,CACxC,0BAAc,EACd;IACE,MAAM,EAAE,sBAAU;IAClB,SAAS,EAAE,0BAAS,CAAC,MAAM;CAC5B,CACF,CAAC;AACF,MAAM,gBAAgB,GAAG,IAAI,6BAAa,CACxC,0BAAc,EACd;IACE,MAAM,EAAE,sBAAU;IAClB,SAAS,EAAE,0BAAS,CAAC,MAAM;CAC5B,CACF,CAAC;AAEF,MAAM,QAAQ,GAAoB,CAAO,KAAa,EAAE,KAAY,EAAE,EAAE;IACtE,MAAM,CAAC,YAAY,EAAE,YAAY,CAAC,GAAG,MAAM,OAAO,CAAC,GAAG,CAAC;QACrD,gBAAgB,CAAC,OAAO,CAAC,KAAK,CAAC;QAC/B,gBAAgB,CAAC,OAAO,CAAC,KAAK,CAAC;KAChC,CAAC,CAAC;IACH,IAAI,CAAC,YAAY;QAAE,MAAM,IAAI,KAAK,CAAC,iCAAiC,CAAC,CAAC;IAEtE,MAAM,CACJ,eAAe,EACf,qBAAqB,EACrB,aAAa,EACb,mBAAmB,EACpB,GAAG,MAAM,OAAO,CAAC,GAAG,CAAC;QACpB,IAAA,4BAAkB,EAAC,YAAY,EAAE,KAAK,CAAC,EAAE,MAAM;QAC/C,IAAA,iCAAuB,EAAC,YAAY,EAAE,KAAK,CAAC,EAAE,OAAO;QACrD,IAAA,0BAAgB,EAAC,KAAK,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AC;IACL,CAAC,CAAC,CAAC;IAEH,OAAO,eAAe,CAAC,WAAW,CAAC,KAAK,CAAC,CAAC;AAC5C,CAAC,CAAA,CAAC;AAEF,MAAM,OAAO,GAAY;IACvB,EAAE,EAAE,GAAG,sBAAU,YAAY;IAC7B,SAAS,EAAE,0BAAS,CAAC,MAAM;IAC3B,QAAQ;CACT,CAAC;AAEF,kBAAe,OAAO,CAAC"}
@@ -73,7 +73,16 @@ function getOrcaNftFetcher(platformId, programId) {
73
73
  !whirlpoolInfo.tokenMintB ||
74
74
  !whirlpoolInfo.tickCurrentIndex)
75
75
  continue;
76
- const element = elementRegistry.addElementConcentratedLiquidity();
76
+ const element = elementRegistry.addElementConcentratedLiquidity({
77
+ link: 'https://www.orca.so/portfolio',
78
+ ref: positionInfo.pubkey.toString(),
79
+ sourceRefs: [
80
+ {
81
+ name: 'Pool',
82
+ address: whirlpoolInfo.pubkey.toString(),
83
+ },
84
+ ],
85
+ });
77
86
  const liquidity = element.setLiquidity({
78
87
  addressA: whirlpoolInfo.tokenMintA,
79
88
  addressB: whirlpoolInfo.tokenMintB,
@@ -1 +1 @@
1
- {"version":3,"file":"getWhirlpoolPositions.js","sourceRoot":"","sources":["../../../../../../packages/plugins/src/plugins/orca/getWhirlpoolPositions.ts"],"names":[],"mappings":";;;;;;;;;;;;AAAA,+DAIoC;AACpC,6CAA4C;AAC5C,2CAIqB;AACrB,iDAAsD;AACtD,+CAG4B;AAE5B,mDAAgE;AAEhE,iDAAwE;AACxE,gFAA6E;AAGhE,QAAA,qBAAqB,GAAG,iBAAiB,CACpD,sBAAc,EACd,4BAAgB,CACjB,CAAC;AAEF,SAAgB,iBAAiB,CAC/B,UAAkB,EAClB,SAAoB;IAEpB,OAAO,CACL,KAAY,EACZ,IAAiC,EACJ,EAAE;;QAC/B,MAAM,MAAM,GAAG,IAAA,yBAAe,GAAE,CAAC;QACjC,MAAM,uBAAuB,GAAgB,EAAE,CAAC;QAEhD,IAAI,CAAC,OAAO,CAA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H,SAAS,CAAC,cAAc,CAAC;oBACvB,OAAO,EAAE,aAAa,CAAC,WAAW,CAAC,CAAC,CAAC,CAAC,IAAI;oBAC1C,MAAM,EAAE,cAAc,CAAC,WAAW;iBACnC,CAAC,CAAC;gBAEH,SAAS,CAAC,cAAc,CAAC;oBACvB,OAAO,EAAE,aAAa,CAAC,WAAW,CAAC,CAAC,CAAC,CAAC,IAAI;oBAC1C,MAAM,EAAE,cAAc,CAAC,WAAW;iBACnC,CAAC,CAAC;YACL,CAAC;QACH,CAAC;QAED,OAAO,eAAe,CAAC,WAAW,CAAC,KAAK,CAAC,CAAC;IAC5C,CAAC,CAAA,CAAC;AACJ,CAAC;AAnID,8CAmIC"}
1
+ {"version":3,"file":"getWhirlpoolPositions.js","sourceRoot":"","sources":["../../../../../../packages/plugins/src/plugins/orca/getWhirlpoolPositions.ts"],"names":[],"mappings":";;;;;;;;;;;;AAAA,+DAIoC;AACpC,6CAA4C;AAC5C,2CAIqB;AACrB,iDAAsD;AACtD,+CAG4B;AAE5B,mDAAgE;AAEhE,iDAAwE;AACxE,gFAA6E;AAGhE,QAAA,qBAAqB,GAAG,iBAAiB,CACpD,sBAAc,EACd,4BAAgB,CACjB,CAAC;AAEF,SAAgB,iBAAiB,CAC/B,UAAkB,EAClB,SAAoB;IAEpB,OAAO,CACL,KAAY,EACZ,IAAiC,EACJ,EAAE;;QAC/B,MAAM,MAAM,GAAG,IAAA,yBAAe,GAAE,CAAC;QACjC,MAAM,uBAAuB,GAAgB,EAAE,CAAC;QAEhD,IAAI,CAAC,OAAO,CAAC,CAAC,GAAG,EAAE,EAAE;YACnB,MAAM,OAAO,GAAG,IAAI,mBAAS,CAAC,GAAG,CAAC,IAAI,CAAC,OAAO,CAAC,CAAC;YAEhD,MAAM,YAAY,GAAG,CAAC,MAAM,CAAC,IAAI,CAAC,UAAU,CAAC,EAAE,OAAO,CAAC,QAAQ,EAAE,CAAC,CAAC;YAEnE,MAAM,CAAC,cAAc,CAAC,GAAG,m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AAa,CAAC,WAAW,CAAC,CAAC,CAAC,CAAC,IAAI;oBAC1C,MAAM,EAAE,cAAc,CAAC,WAAW;iBACnC,CAAC,CAAC;gBAEH,SAAS,CAAC,cAAc,CAAC;oBACvB,OAAO,EAAE,aAAa,CAAC,WAAW,CAAC,CAAC,CAAC,CAAC,IAAI;oBAC1C,MAAM,EAAE,cAAc,CAAC,WAAW;iBACnC,CAAC,CAAC;YACL,CAAC;QACH,CAAC;QAED,OAAO,eAAe,CAAC,WAAW,CAAC,KAAK,CAAC,CAAC;IAC5C,CAAC,CAAA,CAAC;AACJ,CAAC;AA5ID,8CA4IC"}
@@ -82,7 +82,7 @@ const executor = (owner, cache) => __awaiter(void 0, void 0, void 0, function* (
82
82
  label: 'Deposit',
83
83
  networkId: portfolio_core_1.NetworkId.solana,
84
84
  platformId: constants_1.platformId,
85
- data: { assets },
85
+ data: { assets, link: 'https://app.parcl.co/lp' },
86
86
  value: (0, portfolio_core_1.getUsdValueSum)(assets.map((asset) => asset.value)),
87
87
  },
88
88
  ];
@@ -1 +1 @@
1
- {"version":3,"file":"depositsFetcher.js","sourceRoot":"","sources":["../../../../../../packages/plugins/src/plugins/parcl/depositsFetcher.ts"],"names":[],"mappings":";;;;;;;;;;;;;;AAAA,+DAKoC;AAGpC,2CAAyC;AACzC,iDAAsD;AACtD,+CAG4B;AAC5B,uCAImB;AACnB,qGAA6E;AAC7E,uCAImB;AACnB,kFAA+E;AAE/E,MAAM,UAAU,GAAG,EAAE,GAAG,IAAI,GAAG,EAAE,GAAG,EAAE,GAAG,EAAE,CAAC;AAE5C,MAAM,QAAQ,GAAoB,CAAO,KAAa,EAAE,KAAY,EAAE,EAAE;IACtE,MAAM,MAAM,GAAG,IAAA,yBAAe,GAAE,CAAC;IAEjC,MAAM,YAAY,GAAG,MAAM,IAAA,2CAAoB,EAC7C,MAAM,EACN,yBAAe,EACf,IAAA,4BAAkB,EAAC,KAAK,CAAC,CAC1B,CAAC;IAEF,IAAI,EAAE,GAA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,CAAC,MAAM,KAAK,CAAC;QAAE,OAAO,EAAE,CAAC;IAEnC,OAAO;QACL;YACE,IAAI,EAAE,qCAAoB,CAAC,QAAQ;YACnC,KAAK,EAAE,SAAS;YAChB,SAAS,EAAE,0BAAS,CAAC,MAAM;YAC3B,UAAU,EAAV,sBAAU;YACV,IAAI,EAAE,EAAE,MAAM,EAAE,IAAI,EAAE,yBAAyB,EAAE;YACjD,KAAK,EAAE,IAAA,+BAAc,EAAC,MAAM,CAAC,GAAG,CAAC,CAAC,KAAK,EAAE,EAAE,CAAC,KAAK,CAAC,KAAK,CAAC,CAAC;SAC1D;KACF,CAAC;AACJ,CAAC,CAAA,CAAC;AAEF,MAAM,OAAO,GAAY;IACvB,EAAE,EAAE,GAAG,sBAAU,WAAW;IAC5B,SAAS,EAAE,0BAAS,CAAC,MAAM;IAC3B,QAAQ;CACT,CAAC;AAEF,kBAAe,OAAO,CAAC"}
@@ -31,7 +31,7 @@ const executor = (owner, cache) => __awaiter(void 0, void 0, void 0, function* (
31
31
  for (const account of accounts) {
32
32
  if (account.margin.isZero())
33
33
  continue;
34
- assets.push(Object.assign(Object.assign({}, (0, tokenPriceToAssetToken_1.default)(solana_1.usdcSolanaMint, account.margin.dividedBy(Math.pow(10, solana_1.usdcSolanaDecimals)).toNumber(), portfolio_core_1.NetworkId.solana, usdcTokenPrice)), { attributes: {} }));
34
+ assets.push(Object.assign(Object.assign({}, (0, tokenPriceToAssetToken_1.default)(solana_1.usdcSolanaMint, account.margin.dividedBy(Math.pow(10, solana_1.usdcSolanaDecimals)).toNumber(), portfolio_core_1.NetworkId.solana, usdcTokenPrice)), { ref: account.pubkey.toString() }));
35
35
  }
36
36
  if (assets.length === 0)
37
37
  return [];
@@ -1 +1 @@
1
- {"version":3,"file":"marginFetcher.js","sourceRoot":"","sources":["../../../../../../packages/plugins/src/plugins/parcl/marginFetcher.ts"],"names":[],"mappings":";;;;;;;;;;;;;;AAAA,+DAKoC;AAEpC,2CAAoD;AAEpD,i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AChB,cAAc,CACf,KACD,GAAG,EAAE,OAAO,CAAC,MAAM,CAAC,QAAQ,EAAE,IAC9B,CAAC;IACL,CAAC;IACD,IAAI,MAAM,CAAC,MAAM,KAAK,CAAC;QAAE,OAAO,EAAE,CAAC;IAEnC,OAAO;QACL;YACE,IAAI,EAAE,qCAAoB,CAAC,QAAQ;YACnC,KAAK,EAAE,QAAQ;YACf,SAAS,EAAE,0BAAS,CAAC,MAAM;YAC3B,UAAU,EAAV,sBAAU;YACV,IAAI,EAAE,EAAE,MAAM,EAAE;YAChB,KAAK,EAAE,IAAA,+BAAc,EAAC,MAAM,CAAC,GAAG,CAAC,CAAC,KAAK,EAAE,EAAE,CAAC,KAAK,CAAC,KAAK,CAAC,CAAC;SAC1D;KACF,CAAC;AACJ,CAAC,CAAA,CAAC;AAEF,MAAM,OAAO,GAAY;IACvB,EAAE,EAAE,GAAG,sBAAU,SAAS;IAC1B,SAAS,EAAE,0BAAS,CAAC,MAAM;IAC3B,QAAQ;CACT,CAAC;AAEF,kBAAe,OAAO,CAAC"}
@@ -43,9 +43,12 @@ const executor = (owner, cache) => __awaiter(void 0, void 0, void 0, function* (
43
43
  label: 'Staked',
44
44
  link: 'https://stake.parcllimited.com/',
45
45
  });
46
- element.addAsset({
47
- address: constants_1.prclMint,
48
- amount: tokenBalances.reduce((sum, current) => sum + current, 0),
46
+ accs.forEach((acc, i) => {
47
+ element.addAsset({
48
+ address: constants_1.prclMint,
49
+ amount: tokenBalances[i],
50
+ ref: acc.pubkey.toString(),
51
+ });
49
52
  });
50
53
  return elementRegistry.getElements(cache);
51
54
  });
@@ -1 +1 @@
1
- {"version":3,"file":"stakingFetcher.js","sourceRoot":"","sources":["../../../../../../packages/plugins/src/plugins/parcl/stakingFetcher.ts"],"names":[],"mappings":";;;;;;;;;;;AAAA,+DAAuD;AACvD,6CAA4C;AAE5C,2CAAqE;AAErE,iDAAsD;AACtD,+CAAwD;AACxD,gFAA6E;AAE7E,MAAM,QAAQ,GAAoB,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AAC,CAAC;KACjE,CAAC,CAAC;IAEH,OAAO,eAAe,CAAC,WAAW,CAAC,KAAK,CAAC,CAAC;AAC5C,CAAC,CAAA,CAAC;AAEF,MAAM,OAAO,GAAY;IACvB,EAAE,EAAE,GAAG,sBAAU,UAAU;IAC3B,SAAS,EAAE,0BAAS,CAAC,MAAM;IAC3B,QAAQ;CACT,CAAC;AAEF,kBAAe,OAAO,CAAC"}
1
+ {"version":3,"file":"stakingFetcher.js","sourceRoot":"","sources":["../../../../../../packages/plugins/src/plugins/parcl/stakingFetcher.ts"],"names":[],"mappings":";;;;;;;;;;;AAAA,+DAAuD;AACvD,6CAA4C;AAE5C,2CAAqE;AAErE,iDAAsD;AACtD,+CAAwD;AACxD,gFAA6E;AAE7E,MAAM,QAAQ,GAAoB,CAAO,KAAa,EAAE,KAAY,EAAE,EAAE;IACtE,MAAM,MAAM,GAAG,IAAA,yBAAe,GAAE,CAAC;IAEjC,0HAA0H;IAE1H,MAAM,IAAI,GAAG,MAAM,IAAA,2BAAkB,EAAC,MAAM,EAAE,4BAAgB,EAAE;QAC9D;YACE,MAAM,EAAE;gBACN,MAAM,EAAE,CAAC;gBACT,KAAK,EAAE,aAAa;aACrB;SACF;QACD;YACE,MAAM,EAAE;gBACN,MAAM,EAAE,CAAC;gBACT,KAAK,EAAE,KAAK;aACb;SACF;KACF,CAAC,CAAC;IAEH,IAAI,IAAI,CAAC,MAAM,KAAK,CAAC;QAAE,OAAO,EAAE,CAAC;IAEjC,MAAM,aAAa,GAAG,MAAM,OAAO,CAAC,GAAG,CACrC,IAAI,CAAC,GAAG,CAAC,CAAO,GAAG,EAAE,EAAE;QACrB,MAAM,YAAY,GAAG,MAAM,MAAM,CAAC,sBAAsB,CACtD,mBAAS,CAAC,sBAAsB,CAC9B,CAAC,MAAM,CAAC,IAAI,CAAC,SAAS,CAAC,EAAE,GAAG,CAAC,MAAM,CAAC,QAAQ,EAAE,CAAC,EAC/C,4BAAgB,CACjB,CAAC,CAAC,CAAC,CACL,CAAC;QAEF,OAAO,MAAM,CAAC,YAAY,CAAC,KAAK,CAAC,MAAM,CAAC,CAAC;IAC3C,CAAC,CAAA,CAAC,CACH,CAAC;IAEF,MAAM,eAAe,GAAG,IAAI,iCAAe,CAAC,0BAAS,CAAC,MAAM,EAAE,sBAAU,CAAC,CAAC;IAC1E,MAAM,OAAO,GAAG,eAAe,CAAC,kBAAkB,CAAC;QACjD,KAAK,EAAE,QAAQ;QACf,IAAI,EAAE,iCAAiC;KACxC,CAAC,CAAC;IAEH,IAAI,CAAC,OAAO,CAAC,CAAC,GAAG,EAAE,CAAC,EAAE,EAAE;QACtB,OAAO,CAAC,QAAQ,CAAC;YACf,OAAO,EAAE,oBAAQ;YACjB,MAAM,EAAE,aAAa,CAAC,CAAC,CAAC;YACxB,GAAG,EAAE,GAAG,CAAC,MAAM,CAAC,QAAQ,EAAE;SAC3B,CAAC,CAAC;IACL,CAAC,CAAC,CAAC;IAEH,OAAO,eAAe,CAAC,WAAW,CAAC,KAAK,CAAC,CAAC;AAC5C,CAAC,CAAA,CAAC;AAEF,MAAM,OAAO,GAAY;IACvB,EAAE,EAAE,GAAG,sBAAU,UAAU;IAC3B,SAAS,EAAE,0BAAS,CAAC,MAAM;IAC3B,QAAQ;CACT,CAAC;AAEF,kBAAe,OAAO,CAAC"}
@@ -27,7 +27,12 @@ const executor = (owner, cache) => __awaiter(void 0, void 0, void 0, function* (
27
27
  if (typeof res.data === 'string')
28
28
  return [];
29
29
  const registry = new ElementRegistry_1.ElementRegistry(portfolio_core_1.NetworkId.solana, constants_1.platformId);
30
- registry.addElementMultiple({ label: 'Staked' }).addAsset({
30
+ registry
31
+ .addElementMultiple({
32
+ label: 'Staked',
33
+ link: 'https://photofinish.live/crown',
34
+ })
35
+ .addAsset({
31
36
  address: constants_1.crownMint,
32
37
  amount: res.data,
33
38
  alreadyShifted: true,
@@ -1 +1 @@
1
- {"version":3,"file":"stakingFetcher.js","sourceRoot":"","sources":["../../../../../../packages/plugins/src/plugins/photofinish/stakingFetcher.ts"],"names":[],"mappings":";;;;;;;;;;;;;;AAAA,+DAAuD;AACvD,kDAA0B;AAE1B,2CAA4D;AAE5D,gFAA6E;AAE7E,MAAM,QAAQ,GAAoB,CAAO,KAAa,EAAE,KAAY,EAAE,EAAE;IACtE,IAAI,GAAG,CAAC;IACR,IAAI,CAAC;QACH,GAAG,GAAG,MAAM,eAAK,CAAC,GAAG,CAAC,kBAAM,GAAG,KAAK,CAAC,CAAC;IACxC,CAAC;IAAC,OAAO,GAAG,EAAE,CAAC;QACb,OAAO,EAAE,CAAC;IACZ,CAAC;IAED,IAAI,OAAO,GAAG,CAAC,IAAI,KAAK,QAAQ;QAAE,OAAO,EAAE,CAAC;IAE5C,MAAM,QAAQ,GAAG,IAAI,iCAAe,CAAC,0BAAS,CAAC,MAAM,EAAE,sBAAU,CAAC,CAAC;IAEnE,QAAQ,CAAC,kBAAkB,CAAC,EAAE,KAAK,EAAE,QAAQ,EAAE,CAAC,CAAC,QAAQ,CAAC;QACxD,OAAO,EAAE,qBAAS;QAClB,MAAM,EAAE,GAAG,CAAC,IAAI;QAChB,cAAc,EAAE,IAAI;KACrB,CAAC,CAAC;IAEH,OAAO,QAAQ,CAAC,WAAW,CAAC,KAAK,CAAC,CAAC;AACrC,CAAC,CAAA,CAAC;AAEF,MAAM,OAAO,GAAY;IACvB,EAAE,EAAE,GAAG,sBAAU,UAAU;IAC3B,SAAS,EAAE,0BAAS,CAAC,MAAM;IAC3B,QAAQ;CACT,CAAC;AAEF,kBAAe,OAAO,CAAC"}
1
+ {"version":3,"file":"stakingFetcher.js","sourceRoot":"","sources":["../../../../../../packages/plugins/src/plugins/photofinish/stakingFetcher.ts"],"names":[],"mappings":";;;;;;;;;;;;;;AAAA,+DAAuD;AACvD,kDAA0B;AAE1B,2CAA4D;AAE5D,gFAA6E;AAE7E,MAAM,QAAQ,GAAoB,CAAO,KAAa,EAAE,KAAY,EAAE,EAAE;IACtE,IAAI,GAAG,CAAC;IACR,IAAI,CAAC;QACH,GAAG,GAAG,MAAM,eAAK,CAAC,GAAG,CAAC,kBAAM,GAAG,KAAK,CAAC,CAAC;IACxC,CAAC;IAAC,OAAO,GAAG,EAAE,CAAC;QACb,OAAO,EAAE,CAAC;IACZ,CAAC;IAED,IAAI,OAAO,GAAG,CAAC,IAAI,KAAK,QAAQ;QAAE,OAAO,EAAE,CAAC;IAE5C,MAAM,QAAQ,GAAG,IAAI,iCAAe,CAAC,0BAAS,CAAC,MAAM,EAAE,sBAAU,CAAC,CAAC;IAEnE,QAAQ;SACL,kBAAkB,CAAC;QAClB,KAAK,EAAE,QAAQ;QACf,IAAI,EAAE,gCAAgC;KACvC,CAAC;SACD,QAAQ,CAAC;QACR,OAAO,EAAE,qBAAS;QAClB,MAAM,EAAE,GAAG,CAAC,IAAI;QAChB,cAAc,EAAE,IAAI;KACrB,CAAC,CAAC;IAEL,OAAO,QAAQ,CAAC,WAAW,CAAC,KAAK,CAAC,CAAC;AACrC,CAAC,CAAA,CAAC;AAEF,MAAM,OAAO,GAAY;IACvB,EAAE,EAAE,GAAG,sBAAU,UAAU;IAC3B,SAAS,EAAE,0BAAS,CAAC,MAAM;IAC3B,QAAQ;CACT,CAAC;AAEF,kBAAe,OAAO,CAAC"}
@@ -44,12 +44,12 @@ const executor = (owner, cache) => __awaiter(void 0, void 0, void 0, function* (
44
44
  .times(1000)
45
45
  .toNumber());
46
46
  const isClaimable = unlockingAt.getTime() < Date.now();
47
- assets.push((0, tokenPriceToAssetToken_1.default)(vault.stakeMint, new bignumber_js_1.default(vault.stakeAmount)
47
+ assets.push(Object.assign(Object.assign({}, (0, tokenPriceToAssetToken_1.default)(vault.stakeMint, new bignumber_js_1.default(vault.stakeAmount)
48
48
  .dividedBy(Math.pow(10, tokenPrice.decimals))
49
49
  .toNumber(), portfolio_core_1.NetworkId.solana, tokenPrice, undefined, {
50
50
  isClaimable,
51
51
  lockedUntil: unlockingAt.getTime(),
52
- }));
52
+ })), { ref: vault.pubkey.toString() }));
53
53
  });
54
54
  if (assets.length === 0)
55
55
  return [];
@@ -62,6 +62,7 @@ const executor = (owner, cache) => __awaiter(void 0, void 0, void 0, function* (
62
62
  value: (0, portfolio_core_1.getUsdValueSum)(assets.map((a) => a.value)),
63
63
  data: {
64
64
  assets,
65
+ link: 'https://app.picasso.network/restake',
65
66
  },
66
67
  },
67
68
  ];
@@ -1 +1 @@
1
- {"version":3,"file":"unstakingPositionsFetcher.js","sourceRoot":"","sources":["../../../../../../packages/plugins/src/plugins/picasso/unstakingPositionsFetcher.ts"],"names":[],"mappings":";;;;;;;;;;;;;;AAAA,+DAKoC;AACpC,gEAAqC;AAErC,2CAIqB;AAErB,qGAA6E;AAE7E,kEAA+D;AAE/D,MAAM,aAAa,GAAG,IAAI,6BAAa,CAAU,iCAAqB,EAAE;IACtE,MAAM,EAAE,oCAAwB;IAChC,SAAS,EAAE,0BAAS,CAAC,MAAM;CAC5B,CAAC,CAAC;AAEH,MAAM,QAAQ,GAAoB,CAAO,KAAa,EAAE,KAAY,EAAE,EAAE;IACtE,0CAA0C;IAC1C,8DAA8D;IAE9D,MAAM,SAAS,GAAG,MAAM,aAAa,CAAC,OAAO,CAAC,KAAK,CAAC,CAAC;IAErD,IAAI,CAAC,SAAS,IAAI,SAAS,CAAC,MAAM,KAAK,CAAC;QAAE,OAAO,EAAE,CAAC;IAEpD,MAAM,QAAQ,GAAG,SAAS,CAAC,MAAM,CAC/B,CAAC,CAAC,EAAE,EAAE,WAAC,OAAA,CAAA,MAAA,CAAC,CAAC,iBAAiB,0CAAE,KAAK,MAAK,KAAK,CAAA,EAAA,CAC5C,CAAC;IAEF,IAAI,QAAQ,CAAC,MAAM,KAAK,CAAC;QAAE,OAAO,EAAE,CAAC;IAErC,MAAM,UAAU,GAAG;QACjB,GAAG,IAAI,GAAG,CAAC,QAAQ,CAAC,GAAG,CAAC,CAAC,KAAK,EAAE,EAAE,CAAC,KAAK,CAAC,SAAS,CAAC,CAAC,IAAI,EAAE,C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YACnC,KAAK,EAAE,IAAA,+BAAc,EAAC,MAAM,CAAC,GAAG,CAAC,CAAC,CAAC,EAAE,EAAE,CAAC,CAAC,CAAC,KAAK,CAAC,CAAC;YACjD,IAAI,EAAE;gBACJ,MAAM;aACP;SACF;KACF,CAAC;AACJ,CAAC,CAAA,CAAC;AAEF,MAAM,OAAO,GAAY;IACvB,EAAE,EAAE,GAAG,sBAAU,sBAAsB;IACvC,SAAS,EAAE,0BAAS,CAAC,MAAM;IAC3B,QAAQ;CACT,CAAC;AAEF,kBAAe,OAAO,CAAC"}
1
+ {"version":3,"file":"unstakingPositionsFetcher.js","sourceRoot":"","sources":["../../../../../../packages/plugins/src/plugins/picasso/unstakingPositionsFetcher.ts"],"names":[],"mappings":";;;;;;;;;;;;;;AAAA,+DAKoC;AACpC,gEAAqC;AAErC,2CAIqB;AAErB,qGAA6E;AAE7E,kEAA+D;AAG/D,MAAM,aAAa,GAAG,IAAI,6BAAa,CACrC,iCAAqB,EACrB;IACE,MAAM,EAAE,oCAAwB;IAChC,SAAS,EAAE,0BAAS,CAAC,MAAM;CAC5B,CACF,CAAC;AAEF,MAAM,QAAQ,GAAoB,CAAO,KAAa,EAAE,KAAY,EAAE,EAAE;IACtE,0CAA0C;IAC1C,8DAA8D;IAE9D,MAAM,SAAS,GAAG,MAAM,aAAa,CAAC,OAAO,CAAC,KAAK,CAAC,CAAC;IAErD,IAAI,CAAC,SAAS,IAAI,SAAS,CAAC,MAAM,KAAK,CAAC;QAAE,OAAO,EAAE,CAAC;IAEpD,MAAM,QAAQ,GAAG,SAAS,CAAC,MAAM,CAC/B,CAAC,CAAC,EAAE,EAAE,WAAC,OAAA,CAAA,MAAA,CAAC,CAAC,iBAAiB,0CAAE,KAAK,MAAK,KAAK,CAAA,EAAA,CAC5C,CAAC;IAEF,IAAI,QAAQ,CAAC,MAAM,KAAK,CAAC;QAAE,OAAO,EAAE,CAAC;IAErC,MAAM,UAAU,GAAG;QACjB,GAAG,IAAI,GAAG,CAA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O,EAAE,CAAC;IAEnC,OAAO;QACL;YACE,SAAS,EAAE,0BAAS,CAAC,MAAM;YAC3B,KAAK,EAAE,QAAQ;YACf,UAAU,EAAV,sBAAU;YACV,IAAI,EAAE,qCAAoB,CAAC,QAAQ;YACnC,KAAK,EAAE,IAAA,+BAAc,EAAC,MAAM,CAAC,GAAG,CAAC,CAAC,CAAC,EAAE,EAAE,CAAC,CAAC,CAAC,KAAK,CAAC,CAAC;YACjD,IAAI,EAAE;gBACJ,MAAM;gBACN,IAAI,EAAE,qCAAqC;aAC5C;SACF;KACF,CAAC;AACJ,CAAC,CAAA,CAAC;AAEF,MAAM,OAAO,GAAY;IACvB,EAAE,EAAE,GAAG,sBAAU,sBAAsB;IACvC,SAAS,EAAE,0BAAS,CAAC,MAAM;IAC3B,QAAQ;CACT,CAAC;AAEF,kBAAe,OAAO,CAAC"}
@@ -27,12 +27,14 @@ const calculatePositions = (mergeMinerAccounts, minerAccounts, replicaMinerAccou
27
27
  const primaryQuarryAccount = quarryAccounts.find((q) => q.pubkey.toString() === primaryQuarry.quarry.toString());
28
28
  if (!primaryQuarryAccount)
29
29
  return;
30
+ let minerAccount;
30
31
  if ((0, helpers_1.isMinerAccount)(account)) {
32
+ minerAccount = account;
31
33
  rewardsTokenInfo.push(primaryRewarder.rewardsTokenInfo);
32
34
  rewardsBalance.push((0, getClaimableRewards_1.getClaimableRewards)(primaryQuarryAccount, account));
33
35
  }
34
36
  else {
35
- const minerAccount = replicaMinerAccounts[i].find((a) => a.quarry === primaryQuarryAccount.pubkey.toString());
37
+ minerAccount = replicaMinerAccounts[i].find((a) => a.quarry === primaryQuarryAccount.pubkey.toString());
36
38
  if (!minerAccount)
37
39
  return;
38
40
  rewardsTokenInfo.push(primaryRewarder.rewardsTokenInfo);
@@ -55,6 +57,10 @@ const calculatePositions = (mergeMinerAccounts, minerAccounts, replicaMinerAccou
55
57
  });
56
58
  }
57
59
  positions.push({
60
+ ref: minerAccount.pubkey.toString(),
61
+ sourceRefs: [
62
+ { name: 'Pool', address: primaryQuarryAccount.pubkey.toString() },
63
+ ],
58
64
  primaryRewarder: {
59
65
  slug: primaryRewarder.slug,
60
66
  name: (_a = primaryRewarder.info) === null || _a === void 0 ? void 0 : _a.name,
@@ -1 +1 @@
1
- {"version":3,"file":"calculatePositions.js","sourceRoot":"","sources":["../../../../../../packages/plugins/src/plugins/quarry/calculatePositions.ts"],"names":[],"mappings":";;;AAAA,6CAA4C;AAW5C,uCAA0D;AAC1D,+DAA4D;AAErD,MAAM,kBAAkB,GAAG,CAChC,kBAA+C,EAC/C,aAAqC,EACrC,oBAA8C,EAC9C,YAAwB,EACxB,cAA2C,EAC3C,KAAa,EACb,EAAE;IACF,MAAM,SAAS,GAAe,EAAE,CAAC;IAEjC,MAAM,UAAU,GAAG,IAAA,uBAAa,EAAC,YAAY,EAAE,IAAI,mBAAS,CAAC,KAAK,CAAC,CAAC,CAAC;IAErE,CAAC,GAAG,kBAAkB,EAAE,GAAG,aAAa,CAAC,CAAC,OAAO,CAAC,CAAC,OAAO,EAAE,CAAC,EAAE,EAAE;;QAC/D,IAAI,CAAC,OAAO;YAAE,OAAO;QAErB,MAAM,SAAS,GAAG,UAAU,CAAC,IAAI,CAAC,CAAC,CAAC,EAAE,EAAE,CACtC,IAAA,wBAAc,EAAC,OAAO,CAAC;YACrB,CAAC,CAAC,CAAC,CAAC,UAAU,CAAC,QAAQ,EAAE,KAAK,OAAO,CAAC,MAAM,CAAC,QAAQ,EAAE;YACvD,CAAC,CAAC,CAAC,CAAC,EAAE,CAAC,QAAQ,EAAE,KAAK,OAAO,CAAC,MAAM,CAAC,QAAQ,EAAE,CAClD,CAAC;QACF,IAAI,CAAC,SAAS;YAAE,OAAO;QAEvB,MAAM,eAAe,GAAG,YAAY,CAAC,IAAI,CACvC,CAAC,CAAC,EAAE,EAAE,CAAC,CAAC,CAAC,QAAQ,KAAK,SAAS,CAAC,QAAQ,CAAC,QAAQ,EAAE,CACpD,CAAC;QACF,IAAI,CA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,eAAe,EAAE,aAAa,CAAC,gBAAgB;YAC/C,gBAAgB;YAChB,cAAc;SACf,CAAC,CAAC;IACL,CAAC,CAAC,CAAC;IAEH,OAAO,SAAS,CAAC;AACnB,CAAC,CAAC;AA7FW,QAAA,kBAAkB,sBA6F7B"}
1
+ {"version":3,"file":"calculatePositions.js","sourceRoot":"","sources":["../../../../../../packages/plugins/src/plugins/quarry/calculatePositions.ts"],"names":[],"mappings":";;;AAAA,6CAA4C;AAW5C,uCAA0D;AAC1D,+DAA4D;AAErD,MAAM,kBAAkB,GAAG,CAChC,kBAA+C,EAC/C,aAAqC,EACrC,oBAA8C,EAC9C,YAAwB,EACxB,cAA2C,EAC3C,KAAa,EACb,EAAE;IACF,MAAM,SAAS,GAAe,EAAE,CAAC;IAEjC,MAAM,UAAU,GAAG,IAAA,uBAAa,EAAC,YAAY,EAAE,IAAI,mBAAS,CAAC,KAAK,CAAC,CAAC,CAAC;IAErE,CAAC,GAAG,kBAAkB,EAAE,GAAG,aAAa,CAAC,CAAC,OAAO,CAAC,CAAC,OAAO,EAAE,CAAC,EAAE,EAAE;;QAC/D,IAAI,CAAC,OAAO;YAAE,OAAO;QAErB,MAAM,SAAS,GAAG,UAAU,CAAC,IAAI,CAAC,CAAC,CAAC,EAAE,EAAE,CACtC,IAAA,wBAAc,EAAC,OAAO,CAAC;YACrB,CAAC,CAAC,CAAC,CAAC,UAAU,CAAC,QAAQ,EAAE,KAAK,OAAO,CAAC,MAAM,CAAC,QAAQ,EAAE;YACvD,CAAC,CAAC,CAAC,CAAC,EAAE,CAAC,QAAQ,EAAE,KAAK,OAAO,CAAC,MAAM,CAAC,QAAQ,EAAE,CAClD,CAAC;QACF,IAAI,CAAC,SAAS;YAAE,OAAO;QAEvB,MAAM,eAAe,GAAG,YAAY,CAAC,IAAI,CACvC,CAAC,CAAC,EAAE,EAAE,CAAC,CAAC,CAAC,QAAQ,KAAK,SAAS,CAAC,QAAQ,CAAC,QAAQ,EAAE,CACpD,CAAC;Q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E;gBACf,IAAI,EAAE,eAAe,CAAC,IAAI;gBAC1B,IAAI,EAAE,MAAA,eAAe,CAAC,IAAI,0CAAE,IAAI;aACjC;YACD,aAAa,EAAE,IAAA,wBAAc,EAAC,OAAO,CAAC;gBACpC,CAAC,CAAC,OAAO,CAAC,OAAO;gBACjB,CAAC,CAAC,OAAO,CAAC,cAAc;YAC1B,eAAe,EAAE,aAAa,CAAC,gBAAgB;YAC/C,gBAAgB;YAChB,cAAc;SACf,CAAC,CAAC;IACL,CAAC,CAAC,CAAC;IAEH,OAAO,SAAS,CAAC;AACnB,CAAC,CAAC;AAnGW,QAAA,kBAAkB,sBAmG7B"}
@@ -139,6 +139,8 @@ const executor = (owner, cache) => __awaiter(void 0, void 0, void 0, function* (
139
139
  rewardAssetsValue,
140
140
  value,
141
141
  yields: [],
142
+ ref: position.ref,
143
+ sourceRefs: position.sourceRefs,
142
144
  },
143
145
  ],
144
146
  },
@@ -1 +1 @@
1
- {"version":3,"file":"positionsFetcher.js","sourceRoot":"","sources":["../../../../../../packages/plugins/src/plugins/quarry/positionsFetcher.ts"],"names":[],"mappings":";;;;;;;;;;;;;;AAAA,+DAMoC;AACpC,gEAAqC;AACrC,6CAA4C;AAE5C,2CAOqB;AACrB,qDAAyE;AACzE,kDAAmE;AAEnE,iDAAsD;AACtD,+CAI4B;AAQ5B,kEAA+D;AAC/D,qGAA6E;AAC7E,uGAA+E;AAC/E,uCAA4D;AAC5D,6DAA0D;AAE1D,MAAM,aAAa,GAAG,IAAI,6BAAa,CAAa,6BAAiB,EAAE;IACrE,MAAM,EAAE,sBAAU;IAClB,SAAS,EAAE,0BAAS,CAAC,MAAM;CAC5B,CAAC,CAAC;AAEH,MAAM,QAAQ,GAAoB,CAAO,KAAa,EAAE,KAAY,EAAE,EAAE;IACtE,MAAM,UAAU,GAAG,IAAA,yBAAe,GAAE,CAAC;IAErC,MAAM,CAAC,kBAAkB,EAAE,aAAa,CAAC,GAAG,MAAM,OAAO,CAAC,GAAG,C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M;YACR;gBACE,iBAAiB,GAAG,sBAAU,CAAC;QACnC,CAAC;QAED,QAAQ,CAAC,IAAI,CAAC;YACZ,SAAS,EAAE,0BAAS,CAAC,MAAM;YAC3B,KAAK,EAAE,SAAS;YAChB,UAAU,EAAE,iBAAiB;YAC7B,IAAI,EAAE,qCAAoB,CAAC,SAAS;YACpC,KAAK;YACL,IAAI,EACF,iBAAiB,KAAK,sBAAU,CAAC,CAAC,CAAC,eAAe,CAAC,IAAI,CAAC,CAAC,CAAC,oBAAQ,CAAC,IAAI;YACzE,IAAI,EAAE;gBACJ,WAAW,EAAE;oBACX;wBACE,MAAM;wBACN,WAAW;wBACX,YAAY;wBACZ,iBAAiB;wBACjB,KAAK;wBACL,MAAM,EAAE,EAAE;qBACX;iBACF;aACF;SACF,CAAC,CAAC;IACL,CAAC,CAAC,CAAC;IAEH,OAAO,QAAQ,CAAC;AAClB,CAAC,CAAA,CAAC;AAEF,MAAM,OAAO,GAAY;IACvB,EAAE,EAAE,GAAG,sBAAU,YAAY;IAC7B,SAAS,EAAE,0BAAS,CAAC,MAAM;IAC3B,QAAQ;CACT,CAAC;AAEF,kBAAe,OAAO,CAAC"}
1
+ {"version":3,"file":"positionsFetcher.js","sourceRoot":"","sources":["../../../../../../packages/plugins/src/plugins/quarry/positionsFetcher.ts"],"names":[],"mappings":";;;;;;;;;;;;;;AAAA,+DAMoC;AACpC,gEAAqC;AACrC,6CAA4C;AAE5C,2CAOqB;AACrB,qDAAyE;AACzE,kDAAmE;AAEnE,iDAAsD;AACtD,+CAI4B;AAQ5B,kEAA+D;AAC/D,qGAA6E;AAC7E,uGAA+E;AAC/E,uCAA4D;AAC5D,6DAA0D;AAE1D,MAAM,aAAa,GAAG,IAAI,6BAAa,CAAa,6BAAiB,EAAE;IACrE,MAAM,EAAE,sBAAU;IAClB,SAAS,EAAE,0BAAS,CAAC,MAAM;CAC5B,CAAC,CAAC;AAEH,MAAM,QAAQ,GAAoB,CAAO,KAAa,EAAE,KAAY,E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