@kiminix/tp-client 2.10.3 → 2.10.5

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.d.ts CHANGED
@@ -12,6 +12,7 @@ export * from './vouchers/index';
12
12
  export * from './menus/index';
13
13
  export * from './utils/business-utils';
14
14
  export * from './utils/date-utils';
15
+ export * from './utils/math-utils';
15
16
  export * from './enum';
16
17
  export * from './types';
17
18
  export * from './constants';
package/dist/index.js CHANGED
@@ -21,6 +21,7 @@ export * from './menus/index';
21
21
  //utils
22
22
  export * from './utils/business-utils';
23
23
  export * from './utils/date-utils';
24
+ export * from './utils/math-utils';
24
25
  export * from './enum';
25
26
  export * from './types';
26
27
  export * from './constants';
@@ -0,0 +1,4 @@
1
+ export declare class MathUtils {
2
+ static roundTwo(value: number): number;
3
+ static roundThree(value: number): number;
4
+ }
@@ -0,0 +1,14 @@
1
+ var MathUtils = /** @class */ (function () {
2
+ function MathUtils() {
3
+ }
4
+ // round to 2 decimal places
5
+ MathUtils.roundTwo = function (value) {
6
+ return Math.round((value + Number.EPSILON) * 100) / 100;
7
+ };
8
+ // round to 3 decimal places
9
+ MathUtils.roundThree = function (value) {
10
+ return Math.round((value + Number.EPSILON) * 1000) / 1000;
11
+ };
12
+ return MathUtils;
13
+ }());
14
+ export { MathUtils };
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@kiminix/tp-client",
3
- "version": "2.10.3",
3
+ "version": "2.10.5",
4
4
  "main": "dist/index.js",
5
5
  "types": "dist/index.d.ts",
6
6
  "files": [
@@ -1,2 +0,0 @@
1
- export declare class ReservationUtils {
2
- }
@@ -1,6 +0,0 @@
1
- var ReservationUtils = /** @class */ (function () {
2
- function ReservationUtils() {
3
- }
4
- return ReservationUtils;
5
- }());
6
- export { ReservationUtils };