@azuro-org/toolkit 0.1.8 → 2.0.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/dist/index.es.js +4 -4
- package/lib/index.js +3 -3
- package/package.json +2 -2
package/dist/index.es.js
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import {getMarketKey,getMarketName,
|
|
1
|
+
import {getMarketKey,getMarketName,getSelectionName}from'@azuro-org/dictionaries';/******************************************************************************
|
|
2
2
|
Copyright (c) Microsoft Corporation.
|
|
3
3
|
|
|
4
4
|
Permission to use, copy, modify, and/or distribute this software for any
|
|
@@ -42,10 +42,10 @@ function __rest(s, e) {
|
|
|
42
42
|
outcomes.forEach(function (_a) {
|
|
43
43
|
var outcomeId = _a.outcomeId, rest = __rest(_a, ["outcomeId"]);
|
|
44
44
|
// we are using the same key format that was discussed earlier
|
|
45
|
-
var marketKey = getMarketKey(outcomeId, dictionaries);
|
|
45
|
+
var marketKey = getMarketKey({ outcomeId: outcomeId, dictionaries: dictionaries });
|
|
46
46
|
// we are obtaining the human-readable names of each market and the corresponding outcome selections
|
|
47
|
-
var marketName = getMarketName(outcomeId, dictionaries);
|
|
48
|
-
var selectionName =
|
|
47
|
+
var marketName = getMarketName({ outcomeId: outcomeId, dictionaries: dictionaries });
|
|
48
|
+
var selectionName = getSelectionName({ outcomeId: outcomeId, dictionaries: dictionaries });
|
|
49
49
|
var outcome = __assign({ conditionId: conditionId, outcomeId: outcomeId, lpAddress: lpAddress, coreAddress: coreAddress, selectionName: selectionName }, rest);
|
|
50
50
|
if (!marketsMap[marketKey]) {
|
|
51
51
|
marketsMap[marketKey] = {
|
package/lib/index.js
CHANGED
|
@@ -42,10 +42,10 @@ function __rest(s, e) {
|
|
|
42
42
|
outcomes.forEach(function (_a) {
|
|
43
43
|
var outcomeId = _a.outcomeId, rest = __rest(_a, ["outcomeId"]);
|
|
44
44
|
// we are using the same key format that was discussed earlier
|
|
45
|
-
var marketKey = dictionaries.getMarketKey(outcomeId, dictionaries$1);
|
|
45
|
+
var marketKey = dictionaries.getMarketKey({ outcomeId: outcomeId, dictionaries: dictionaries$1 });
|
|
46
46
|
// we are obtaining the human-readable names of each market and the corresponding outcome selections
|
|
47
|
-
var marketName = dictionaries.getMarketName(outcomeId, dictionaries$1);
|
|
48
|
-
var selectionName = dictionaries.
|
|
47
|
+
var marketName = dictionaries.getMarketName({ outcomeId: outcomeId, dictionaries: dictionaries$1 });
|
|
48
|
+
var selectionName = dictionaries.getSelectionName({ outcomeId: outcomeId, dictionaries: dictionaries$1 });
|
|
49
49
|
var outcome = __assign({ conditionId: conditionId, outcomeId: outcomeId, lpAddress: lpAddress, coreAddress: coreAddress, selectionName: selectionName }, rest);
|
|
50
50
|
if (!marketsMap[marketKey]) {
|
|
51
51
|
marketsMap[marketKey] = {
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@azuro-org/toolkit",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "2.0.0",
|
|
4
4
|
"description": "Set of helpers to work with Azuro protocol",
|
|
5
5
|
"module": "dist/index.es.js",
|
|
6
6
|
"main": "lib/index.js",
|
|
@@ -27,7 +27,7 @@
|
|
|
27
27
|
},
|
|
28
28
|
"homepage": "https://github.com/Azuro-protocol/toolkit#readme",
|
|
29
29
|
"peerDependencies": {
|
|
30
|
-
"@azuro-org/dictionaries": "^
|
|
30
|
+
"@azuro-org/dictionaries": "^2.0.2"
|
|
31
31
|
},
|
|
32
32
|
"devDependencies": {
|
|
33
33
|
"@babel/core": "^7.17.0",
|