@sonarwatch/portfolio-core 0.11.15 → 0.11.17
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 +25 -17
- package/package.json +1 -1
- package/src/utils/healthFactorToHealthRatio.d.ts +1 -0
- package/src/utils/healthFactorToHealthRatio.js +10 -0
- package/src/utils/healthFactorToHealthRatio.js.map +1 -0
- package/src/utils/healthRatioToHealthFactor.d.ts +1 -0
- package/src/utils/healthRatioToHealthFactor.js +10 -0
- package/src/utils/healthRatioToHealthFactor.js.map +1 -0
- package/src/utils/index.d.ts +2 -0
- package/src/utils/index.js +2 -0
- package/src/utils/index.js.map +1 -1
package/CHANGELOG.md
CHANGED
|
@@ -2,26 +2,34 @@
|
|
|
2
2
|
|
|
3
3
|
This file was generated using [@jscutlery/semver](https://github.com/jscutlery/semver).
|
|
4
4
|
|
|
5
|
-
## [0.11.
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
## [0.11.14](https://github.com/sonarwatch/portfolio/compare/core-0.11.13...core-0.11.14) (2023-12-18)
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
## [0.11.13](https://github.com/sonarwatch/portfolio/compare/core-0.11.12...core-0.11.13) (2023-12-17)
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
## [0.11.12](https://github.com/sonarwatch/portfolio/compare/core-0.11.11...core-0.11.12) (2023-12-15)
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
## [0.11.11](https://github.com/sonarwatch/portfolio/compare/core-0.11.10...core-0.11.11) (2023-12-15)
|
|
5
|
+
## [0.11.17](https://github.com/sonarwatch/portfolio/compare/core-0.11.16...core-0.11.17) (2023-12-18)
|
|
22
6
|
|
|
23
7
|
|
|
24
8
|
|
|
9
|
+
## [0.11.16](https://github.com/sonarwatch/portfolio/compare/core-0.11.15...core-0.11.16) (2023-12-18)
|
|
10
|
+
|
|
11
|
+
|
|
12
|
+
|
|
13
|
+
## [0.11.15](https://github.com/sonarwatch/portfolio/compare/core-0.11.14...core-0.11.15) (2023-12-18)
|
|
14
|
+
|
|
15
|
+
|
|
16
|
+
|
|
17
|
+
## [0.11.14](https://github.com/sonarwatch/portfolio/compare/core-0.11.13...core-0.11.14) (2023-12-18)
|
|
18
|
+
|
|
19
|
+
|
|
20
|
+
|
|
21
|
+
## [0.11.13](https://github.com/sonarwatch/portfolio/compare/core-0.11.12...core-0.11.13) (2023-12-17)
|
|
22
|
+
|
|
23
|
+
|
|
24
|
+
|
|
25
|
+
## [0.11.12](https://github.com/sonarwatch/portfolio/compare/core-0.11.11...core-0.11.12) (2023-12-15)
|
|
26
|
+
|
|
27
|
+
|
|
28
|
+
|
|
29
|
+
## [0.11.11](https://github.com/sonarwatch/portfolio/compare/core-0.11.10...core-0.11.11) (2023-12-15)
|
|
30
|
+
|
|
31
|
+
|
|
32
|
+
|
|
25
33
|
## [0.11.10](https://github.com/sonarwatch/portfolio/compare/core-0.11.9...core-0.11.10) (2023-12-14)
|
|
26
34
|
|
|
27
35
|
|
package/package.json
CHANGED
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export declare function healthFactorToHealthRatio(healthFactor: number | null): number | null;
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.healthFactorToHealthRatio = void 0;
|
|
4
|
+
function healthFactorToHealthRatio(healthFactor) {
|
|
5
|
+
if (healthFactor === null)
|
|
6
|
+
return null;
|
|
7
|
+
return 1 - 1 / healthFactor;
|
|
8
|
+
}
|
|
9
|
+
exports.healthFactorToHealthRatio = healthFactorToHealthRatio;
|
|
10
|
+
//# sourceMappingURL=healthFactorToHealthRatio.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"healthFactorToHealthRatio.js","sourceRoot":"","sources":["../../../../../packages/core/src/utils/healthFactorToHealthRatio.ts"],"names":[],"mappings":";;;AAAA,SAAgB,yBAAyB,CACvC,YAA2B;IAE3B,IAAI,YAAY,KAAK,IAAI;QAAE,OAAO,IAAI,CAAC;IACvC,OAAO,CAAC,GAAG,CAAC,GAAG,YAAY,CAAC;AAC9B,CAAC;AALD,8DAKC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export declare function healthRatioToHealthFactor(healthRatio: number | null): number | null;
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.healthRatioToHealthFactor = void 0;
|
|
4
|
+
function healthRatioToHealthFactor(healthRatio) {
|
|
5
|
+
if (healthRatio === null)
|
|
6
|
+
return null;
|
|
7
|
+
return 1 / (1 - healthRatio);
|
|
8
|
+
}
|
|
9
|
+
exports.healthRatioToHealthFactor = healthRatioToHealthFactor;
|
|
10
|
+
//# sourceMappingURL=healthRatioToHealthFactor.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"healthRatioToHealthFactor.js","sourceRoot":"","sources":["../../../../../packages/core/src/utils/healthRatioToHealthFactor.ts"],"names":[],"mappings":";;;AAAA,SAAgB,yBAAyB,CACvC,WAA0B;IAE1B,IAAI,WAAW,KAAK,IAAI;QAAE,OAAO,IAAI,CAAC;IACtC,OAAO,CAAC,GAAG,CAAC,CAAC,GAAG,WAAW,CAAC,CAAC;AAC/B,CAAC;AALD,8DAKC"}
|
package/src/utils/index.d.ts
CHANGED
package/src/utils/index.js
CHANGED
|
@@ -47,4 +47,6 @@ __exportStar(require("./getImageFromAsset"), exports);
|
|
|
47
47
|
__exportStar(require("./getImageFromAssets"), exports);
|
|
48
48
|
__exportStar(require("./getLabelFromAsset"), exports);
|
|
49
49
|
__exportStar(require("./getLabelFromAssets"), exports);
|
|
50
|
+
__exportStar(require("./healthFactorToHealthRatio"), exports);
|
|
51
|
+
__exportStar(require("./healthRatioToHealthFactor"), exports);
|
|
50
52
|
//# sourceMappingURL=index.js.map
|
package/src/utils/index.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../../packages/core/src/utils/index.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;AAAA,oDAAkC;AAClC,wDAAsC;AACtC,sDAAoC;AACpC,iDAA+B;AAC/B,sDAAoC;AACpC,kDAAgC;AAChC,uDAAqC;AACrC,4DAA0C;AAC1C,gDAA8B;AAC9B,oDAAkC;AAClC,qDAAmC;AACnC,+DAA6C;AAC7C,2DAAyC;AACzC,uDAAqC;AACrC,mDAAiC;AACjC,wDAAsC;AACtC,+DAA6C;AAC7C,kEAAgD;AAChD,yDAAuC;AACvC,0DAAwC;AACxC,8DAA4C;AAC5C,mDAAiC;AACjC,yDAAuC;AACvC,mEAAiD;AACjD,+CAA6B;AAC7B,yDAAuC;AACvC,0DAAwC;AACxC,4DAA0C;AAC1C,wDAAsC;AACtC,sDAAoC;AACpC,uDAAqC;AACrC,sDAAoC;AACpC,uDAAqC"}
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../../packages/core/src/utils/index.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;AAAA,oDAAkC;AAClC,wDAAsC;AACtC,sDAAoC;AACpC,iDAA+B;AAC/B,sDAAoC;AACpC,kDAAgC;AAChC,uDAAqC;AACrC,4DAA0C;AAC1C,gDAA8B;AAC9B,oDAAkC;AAClC,qDAAmC;AACnC,+DAA6C;AAC7C,2DAAyC;AACzC,uDAAqC;AACrC,mDAAiC;AACjC,wDAAsC;AACtC,+DAA6C;AAC7C,kEAAgD;AAChD,yDAAuC;AACvC,0DAAwC;AACxC,8DAA4C;AAC5C,mDAAiC;AACjC,yDAAuC;AACvC,mEAAiD;AACjD,+CAA6B;AAC7B,yDAAuC;AACvC,0DAAwC;AACxC,4DAA0C;AAC1C,wDAAsC;AACtC,sDAAoC;AACpC,uDAAqC;AACrC,sDAAoC;AACpC,uDAAqC;AACrC,8DAA4C;AAC5C,8DAA4C"}
|