@sonarwatch/portfolio-plugins 0.12.167 → 0.12.169
Sign up to get free protection for your applications and to get access to all the features.
- package/CHANGELOG.md +8 -0
- package/package.json +1 -1
- package/src/plugins/jewel/stakedFetcher.js +2 -2
- package/src/plugins/jewel/stakedFetcher.js.map +1 -1
- package/src/plugins/solayer/constants.d.ts +1 -0
- package/src/plugins/solayer/constants.js +7 -1
- package/src/plugins/solayer/constants.js.map +1 -1
- package/src/plugins/solayer/delegateJob.d.ts +3 -0
- package/src/plugins/solayer/delegateJob.js +49 -0
- package/src/plugins/solayer/delegateJob.js.map +1 -0
- package/src/plugins/solayer/index.js +2 -1
- package/src/plugins/solayer/index.js.map +1 -1
package/CHANGELOG.md
CHANGED
@@ -2,6 +2,14 @@
|
|
2
2
|
|
3
3
|
This file was generated using [@jscutlery/semver](https://github.com/jscutlery/semver).
|
4
4
|
|
5
|
+
## [0.12.169](https://github.com/sonarwatch/portfolio/compare/plugins-0.12.168...plugins-0.12.169) (2024-09-21)
|
6
|
+
|
7
|
+
|
8
|
+
|
9
|
+
## [0.12.168](https://github.com/sonarwatch/portfolio/compare/plugins-0.12.167...plugins-0.12.168) (2024-09-21)
|
10
|
+
|
11
|
+
|
12
|
+
|
5
13
|
## [0.12.167](https://github.com/sonarwatch/portfolio/compare/plugins-0.12.166...plugins-0.12.167) (2024-09-19)
|
6
14
|
|
7
15
|
|
package/package.json
CHANGED
@@ -71,7 +71,7 @@ const executor = (owner, cache) => __awaiter(void 0, void 0, void 0, function* (
|
|
71
71
|
elements.push({
|
72
72
|
type: portfolio_core_1.PortfolioElementType.multiple,
|
73
73
|
label: 'Staked',
|
74
|
-
networkId: portfolio_core_1.NetworkId.
|
74
|
+
networkId: portfolio_core_1.NetworkId.sui,
|
75
75
|
platformId: constants_1.platformId,
|
76
76
|
data: {
|
77
77
|
assets: stakedAssets,
|
@@ -83,7 +83,7 @@ const executor = (owner, cache) => __awaiter(void 0, void 0, void 0, function* (
|
|
83
83
|
elements.push({
|
84
84
|
type: portfolio_core_1.PortfolioElementType.multiple,
|
85
85
|
label: 'Deposit',
|
86
|
-
networkId: portfolio_core_1.NetworkId.
|
86
|
+
networkId: portfolio_core_1.NetworkId.sui,
|
87
87
|
platformId: constants_1.platformId,
|
88
88
|
data: {
|
89
89
|
assets: suiUnstakingAssets,
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"stakedFetcher.js","sourceRoot":"","sources":["../../../../../../packages/plugins/src/plugins/jewel/stakedFetcher.ts"],"names":[],"mappings":";;;;;;;;;;;;;;AAAA,+DAQoC;AACpC,gEAAqC;AAErC,2CAAmE;AAEnE,iDAAmD;AAEnD,qGAA6E;AAC7E,iFAA8E;AAE9E,MAAM,OAAO,GAAG,EAAE,GAAG,EAAE,GAAG,EAAE,GAAG,EAAE,GAAG,IAAI,CAAC;AACzC,MAAM,SAAS,GAAG,CAAC,GAAG,EAAE,GAAG,EAAE,GAAG,EAAE,GAAG,IAAI,CAAC;AAE1C,MAAM,QAAQ,GAAoB,CAAO,KAAa,EAAE,KAAY,EAAE,EAAE;;IACtE,MAAM,MAAM,GAAG,IAAA,sBAAY,GAAE,CAAC;IAE9B,MAAM,SAAS,GAAG,MAAM,OAAO,CAAC,GAAG,CAAC;QAClC,GAAG,4BAAgB,CAAC,GAAG,CAAC,CAAC,IAAI,EAAE,EAAE,CAC/B,IAAA,6CAAqB,EAAC,MAAM,EAAE;YAC5B,QAAQ,EAAE,IAAI,CAAC,QAAQ;YACvB,IAAI,EAAE;gBACJ,IAAI,EAAE,SAAS;gBACf,KAAK,EAAE,KAAK;aACb;SACF,CAAC,CACH;KACF,CAAC,CAAC;IAEH,IAAI,CAAC,SAAS,CAAC,IAAI,CAAC,CAAC,GAAG,EAAE,EAAE,CAAC,GAAG,CAAC,IAAI,CAAC;QAAE,OAAO,EAAE,CAAC;IAElD,MAAM,cAAc,GAAG,MAAM,KAAK,CAAC,mBAAmB,CACpD,4BAAgB,CAAC,GAAG,CAAC,CAAC,IAAI,EAAE,EAAE,CAAC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AY,CAAC,GAAG,CAAC,CAAC,CAAC,EAAE,EAAE,CAAC,CAAC,CAAC,KAAK,CAAC,CAAC;SACxD,CAAC,CAAC;IACL,CAAC;IAED,IAAI,kBAAkB,CAAC,MAAM,KAAK,CAAC,EAAE,CAAC;QACpC,QAAQ,CAAC,IAAI,CAAC;YACZ,IAAI,EAAE,qCAAoB,CAAC,QAAQ;YACnC,KAAK,EAAE,SAAS;YAChB,SAAS,EAAE,0BAAS,CAAC,GAAG;YACxB,UAAU,EAAV,sBAAU;YACV,IAAI,EAAE;gBACJ,MAAM,EAAE,kBAAkB;aAC3B;YACD,KAAK,EAAE,IAAA,+BAAc,EAAC,kBAAkB,CAAC,GAAG,CAAC,CAAC,CAAC,EAAE,EAAE,CAAC,CAAC,CAAC,KAAK,CAAC,CAAC;SAC9D,CAAC,CAAC;IACL,CAAC;IAED,OAAO,QAAQ,CAAC;AAClB,CAAC,CAAA,CAAC;AAEF,MAAM,OAAO,GAAY;IACvB,EAAE,EAAE,GAAG,sBAAU,WAAW;IAC5B,SAAS,EAAE,0BAAS,CAAC,GAAG;IACxB,QAAQ;CACT,CAAC;AAEF,kBAAe,OAAO,CAAC"}
|
@@ -7,3 +7,4 @@ export declare const solayerLstPool = "po1osKDWYF9oiVEGmzKA4eTs8eMveFRMox3bUKazG
|
|
7
7
|
export declare const solayerLstMint = "sSo1wxKKr6zW2hqf5hZrp2CawLibcwi1pMBqk5bg2G4";
|
8
8
|
export declare const solayerRstMint = "sSo14endRuUbvQaJS3dq36Q829a3A6BEfoeeRGJywEh";
|
9
9
|
export declare const solayerLstDecimals = 9;
|
10
|
+
export declare const avsTokens: string[];
|
@@ -1,6 +1,6 @@
|
|
1
1
|
"use strict";
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
3
|
-
exports.solayerLstDecimals = exports.solayerRstMint = exports.solayerLstMint = exports.solayerLstPool = exports.programId = exports.platform = exports.platformId = void 0;
|
3
|
+
exports.avsTokens = exports.solayerLstDecimals = exports.solayerRstMint = exports.solayerLstMint = exports.solayerLstPool = exports.programId = exports.platform = exports.platformId = void 0;
|
4
4
|
const web3_js_1 = require("@solana/web3.js");
|
5
5
|
exports.platformId = 'solayer';
|
6
6
|
exports.platform = {
|
@@ -17,4 +17,10 @@ exports.solayerLstPool = 'po1osKDWYF9oiVEGmzKA4eTs8eMveFRMox3bUKazGN2';
|
|
17
17
|
exports.solayerLstMint = 'sSo1wxKKr6zW2hqf5hZrp2CawLibcwi1pMBqk5bg2G4';
|
18
18
|
exports.solayerRstMint = 'sSo14endRuUbvQaJS3dq36Q829a3A6BEfoeeRGJywEh';
|
19
19
|
exports.solayerLstDecimals = 9;
|
20
|
+
exports.avsTokens = [
|
21
|
+
'sonickAJFiVLcYXx25X9vpF293udaWqDMUCiGtk7dg2',
|
22
|
+
'hash4eTHsuZakZiHg5vfQwFtBaEhhC9SXRYsZm4Br7k',
|
23
|
+
'bonkABCQVasnhyVAvB2zYFSCRMGB6xKhpthKuCnsU5K',
|
24
|
+
'6C41vb9AqJzmbWZ4zi6eCGJz3vSKrwjxfu8N77SRRtyr',
|
25
|
+
];
|
20
26
|
//# sourceMappingURL=constants.js.map
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"constants.js","sourceRoot":"","sources":["../../../../../../packages/plugins/src/plugins/solayer/constants.ts"],"names":[],"mappings":";;;AAAA,6CAA4C;AAG/B,QAAA,UAAU,GAAG,SAAS,CAAC;AACvB,QAAA,QAAQ,GAAa;IAChC,EAAE,EAAE,kBAAU;IACd,IAAI,EAAE,SAAS;IACf,KAAK,EAAE,gDAAgD;IACvD,OAAO,EAAE,sBAAsB;IAC/B,OAAO,EAAE,4BAA4B;IACrC,WAAW,EAAE,SAAS;CACvB,CAAC;AAEW,QAAA,SAAS,GAAG,IAAI,mBAAS,CACpC,6CAA6C,CAC9C,CAAC;AAEF,kFAAkF;AACrE,QAAA,cAAc,GAAG,6CAA6C,CAAC;AAC/D,QAAA,cAAc,GAAG,6CAA6C,CAAC;AAC/D,QAAA,cAAc,GAAG,6CAA6C,CAAC;AAC/D,QAAA,kBAAkB,GAAG,CAAC,CAAC"}
|
1
|
+
{"version":3,"file":"constants.js","sourceRoot":"","sources":["../../../../../../packages/plugins/src/plugins/solayer/constants.ts"],"names":[],"mappings":";;;AAAA,6CAA4C;AAG/B,QAAA,UAAU,GAAG,SAAS,CAAC;AACvB,QAAA,QAAQ,GAAa;IAChC,EAAE,EAAE,kBAAU;IACd,IAAI,EAAE,SAAS;IACf,KAAK,EAAE,gDAAgD;IACvD,OAAO,EAAE,sBAAsB;IAC/B,OAAO,EAAE,4BAA4B;IACrC,WAAW,EAAE,SAAS;CACvB,CAAC;AAEW,QAAA,SAAS,GAAG,IAAI,mBAAS,CACpC,6CAA6C,CAC9C,CAAC;AAEF,kFAAkF;AACrE,QAAA,cAAc,GAAG,6CAA6C,CAAC;AAC/D,QAAA,cAAc,GAAG,6CAA6C,CAAC;AAC/D,QAAA,cAAc,GAAG,6CAA6C,CAAC;AAC/D,QAAA,kBAAkB,GAAG,CAAC,CAAC;AAEvB,QAAA,SAAS,GAAG;IACvB,6CAA6C;IAC7C,6CAA6C;IAC7C,6CAA6C;IAC7C,8CAA8C;CAC/C,CAAC"}
|
@@ -0,0 +1,49 @@
|
|
1
|
+
"use strict";
|
2
|
+
var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {
|
3
|
+
function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
|
4
|
+
return new (P || (P = Promise))(function (resolve, reject) {
|
5
|
+
function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }
|
6
|
+
function rejected(value) { try { step(generator["throw"](value)); } catch (e) { reject(e); } }
|
7
|
+
function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }
|
8
|
+
step((generator = generator.apply(thisArg, _arguments || [])).next());
|
9
|
+
});
|
10
|
+
};
|
11
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
12
|
+
const portfolio_core_1 = require("@sonarwatch/portfolio-core");
|
13
|
+
const constants_1 = require("./constants");
|
14
|
+
const executor = (cache) => __awaiter(void 0, void 0, void 0, function* () {
|
15
|
+
const rstTokenPrice = yield cache.getTokenPrice(constants_1.solayerRstMint, portfolio_core_1.NetworkId.solana);
|
16
|
+
if (!rstTokenPrice)
|
17
|
+
return;
|
18
|
+
const sources = [];
|
19
|
+
constants_1.avsTokens.forEach((avsToken) => {
|
20
|
+
sources.push({
|
21
|
+
address: avsToken,
|
22
|
+
decimals: rstTokenPrice.decimals,
|
23
|
+
id: constants_1.platformId,
|
24
|
+
networkId: portfolio_core_1.NetworkId.solana,
|
25
|
+
platformId: constants_1.platformId,
|
26
|
+
price: rstTokenPrice.price,
|
27
|
+
timestamp: Date.now(),
|
28
|
+
weight: 1,
|
29
|
+
elementName: 'Delegate',
|
30
|
+
underlyings: [
|
31
|
+
{
|
32
|
+
address: constants_1.solayerRstMint,
|
33
|
+
decimals: rstTokenPrice.decimals,
|
34
|
+
amountPerLp: 1,
|
35
|
+
networkId: portfolio_core_1.NetworkId.solana,
|
36
|
+
price: rstTokenPrice.price,
|
37
|
+
},
|
38
|
+
],
|
39
|
+
});
|
40
|
+
});
|
41
|
+
yield cache.setTokenPriceSources(sources);
|
42
|
+
});
|
43
|
+
const job = {
|
44
|
+
id: `${constants_1.platformId}-delegate`,
|
45
|
+
executor,
|
46
|
+
label: 'normal',
|
47
|
+
};
|
48
|
+
exports.default = job;
|
49
|
+
//# sourceMappingURL=delegateJob.js.map
|
@@ -0,0 +1 @@
|
|
1
|
+
{"version":3,"file":"delegateJob.js","sourceRoot":"","sources":["../../../../../../packages/plugins/src/plugins/solayer/delegateJob.ts"],"names":[],"mappings":";;;;;;;;;;;AAAA,+DAAyE;AAGzE,2CAAoE;AAEpE,MAAM,QAAQ,GAAgB,CAAO,KAAY,EAAE,EAAE;IACnD,MAAM,aAAa,GAAG,MAAM,KAAK,CAAC,aAAa,CAC7C,0BAAc,EACd,0BAAS,CAAC,MAAM,CACjB,CAAC;IAEF,IAAI,CAAC,aAAa;QAAE,OAAO;IAE3B,MAAM,OAAO,GAAuB,EAAE,CAAC;IAEvC,qBAAS,CAAC,OAAO,CAAC,CAAC,QAAQ,EAAE,EAAE;QAC7B,OAAO,CAAC,IAAI,CAAC;YACX,OAAO,EAAE,QAAQ;YACjB,QAAQ,EAAE,aAAa,CAAC,QAAQ;YAChC,EAAE,EAAE,sBAAU;YACd,SAAS,EAAE,0BAAS,CAAC,MAAM;YAC3B,UAAU,EAAV,sBAAU;YACV,KAAK,EAAE,aAAa,CAAC,KAAK;YAC1B,SAAS,EAAE,IAAI,CAAC,GAAG,EAAE;YACrB,MAAM,EAAE,CAAC;YACT,WAAW,EAAE,UAAU;YACvB,WAAW,EAAE;gBACX;oBACE,OAAO,EAAE,0BAAc;oBACvB,QAAQ,EAAE,aAAa,CAAC,QAAQ;oBAChC,WAAW,EAAE,CAAC;oBACd,SAAS,EAAE,0BAAS,CAAC,MAAM;oBAC3B,KAAK,EAAE,aAAa,CAAC,KAAK;iBAC3B;aACF;SACF,CAAC,CAAC;IACL,CAAC,CAAC,CAAC;IAEH,MAAM,KAAK,CAAC,oBAAoB,CAAC,OAAO,CAAC,CAAC;AAC5C,CAAC,CAAA,CAAC;AAEF,MAAM,GAAG,GAAQ;IACf,EAAE,EAAE,GAAG,sBAAU,WAAW;IAC5B,QAAQ;IACR,KAAK,EAAE,QAAQ;CAChB,CAAC;AACF,kBAAe,GAAG,CAAC"}
|
@@ -6,7 +6,8 @@ Object.defineProperty(exports, "__esModule", { value: true });
|
|
6
6
|
exports.fetchers = exports.jobs = exports.platforms = void 0;
|
7
7
|
const constants_1 = require("./constants");
|
8
8
|
const poolsJob_1 = __importDefault(require("./poolsJob"));
|
9
|
+
const delegateJob_1 = __importDefault(require("./delegateJob"));
|
9
10
|
exports.platforms = [constants_1.platform];
|
10
|
-
exports.jobs = [poolsJob_1.default];
|
11
|
+
exports.jobs = [poolsJob_1.default, delegateJob_1.default];
|
11
12
|
exports.fetchers = [];
|
12
13
|
//# sourceMappingURL=index.js.map
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../../../packages/plugins/src/plugins/solayer/index.ts"],"names":[],"mappings":";;;;;;AAGA,2CAAuC;AACvC,0DAAkC;
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../../../packages/plugins/src/plugins/solayer/index.ts"],"names":[],"mappings":";;;;;;AAGA,2CAAuC;AACvC,0DAAkC;AAClC,gEAAwC;AAE3B,QAAA,SAAS,GAAe,CAAC,oBAAQ,CAAC,CAAC;AACnC,QAAA,IAAI,GAAU,CAAC,kBAAQ,EAAE,qBAAW,CAAC,CAAC;AACtC,QAAA,QAAQ,GAAc,EAAE,CAAC"}
|