@leather.io/utils 0.10.1 → 0.10.3

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.
@@ -1,5 +1,5 @@
1
1
 
2
- > @leather.io/utils@0.10.1 build /home/runner/work/mono/mono/packages/utils
2
+ > @leather.io/utils@0.10.3 build /home/runner/work/mono/mono/packages/utils
3
3
  > tsup
4
4
 
5
5
  CLI Building entry: src/index.ts
@@ -13,5 +13,5 @@
13
13
  ESM dist/index.js.map 25.92 KB
14
14
  ESM ⚡️ Build success in 20ms
15
15
  DTS Build start
16
- DTS ⚡️ Build success in 1363ms
17
- DTS dist/index.d.ts 6.07 KB
16
+ DTS ⚡️ Build success in 1382ms
17
+ DTS dist/index.d.ts 6.48 KB
package/CHANGELOG.md CHANGED
@@ -49,6 +49,22 @@
49
49
  * @leather.io/models bumped to 0.9.0
50
50
  * @leather.io/rpc bumped to 1.0.4
51
51
 
52
+ ### Dependencies
53
+
54
+ * The following workspace dependencies were updated
55
+ * dependencies
56
+ * @leather.io/constants bumped to 0.8.2
57
+ * @leather.io/models bumped to 0.10.2
58
+ * @leather.io/rpc bumped to 2.0.2
59
+ * devDependencies
60
+ * @leather.io/tsconfig-config bumped to 0.5.1
61
+
62
+ ### Dependencies
63
+
64
+ * The following workspace dependencies were updated
65
+ * dependencies
66
+ * @leather.io/rpc bumped to 2.1.0
67
+
52
68
  ## [0.10.1](https://github.com/leather-io/mono/compare/@leather.io/utils-v0.10.0...@leather.io/utils-v0.10.1) (2024-07-11)
53
69
 
54
70
 
package/dist/index.d.ts CHANGED
@@ -24,7 +24,17 @@ declare function convertAmountToBaseUnit(num: Money | BigNumber$1, decimals?: nu
24
24
  declare function subtractMoney(xAmount: Money, yAmount: Money): Money;
25
25
  declare function sumMoney(moneysArr: Money[]): Money;
26
26
 
27
+ /**
28
+ * @param value Amount described in currency's primary unit
29
+ * @param symbol Identifying letter code, e.g. EUR
30
+ * @param resolution Optional, required if value not known at build-time
31
+ */
27
32
  declare function createMoneyFromDecimal(value: NumType, symbol: Currencies, resolution?: number): Money;
33
+ /**
34
+ * @param value Amount described in currency's fractional base unit, e.g. cents for USD amounts
35
+ * @param symbol Identifying letter code, e.g. EUR
36
+ * @param resolution Optional, required if value not known at build-time
37
+ */
28
38
  declare function createMoney(value: NumType, symbol: Currencies, resolution?: number): Money;
29
39
  declare function formatMoney({ amount, symbol, decimals }: Money): string;
30
40
  declare function formatMoneyWithoutSymbol({ amount, decimals }: Money): string;
package/package.json CHANGED
@@ -2,7 +2,7 @@
2
2
  "name": "@leather.io/utils",
3
3
  "author": "Leather.io contact@leather.io",
4
4
  "description": "Shared bitcoin utilities",
5
- "version": "0.10.1",
5
+ "version": "0.10.3",
6
6
  "license": "MIT",
7
7
  "homepage": "https://github.com/leather-io/mono/tree/dev/packages/utils",
8
8
  "repository": {
@@ -17,9 +17,9 @@
17
17
  "bugs": "https://github.com/leather-io/mono/issues",
18
18
  "dependencies": {
19
19
  "bignumber.js": "9.1.2",
20
- "@leather.io/constants": "0.8.1",
21
- "@leather.io/models": "0.10.1",
22
- "@leather.io/rpc": "2.0.1"
20
+ "@leather.io/models": "0.10.2",
21
+ "@leather.io/constants": "0.8.2",
22
+ "@leather.io/rpc": "2.1.0"
23
23
  },
24
24
  "devDependencies": {
25
25
  "@vitest/coverage-istanbul": "0.34.6",
@@ -27,10 +27,10 @@
27
27
  "prettier": "3.3.0",
28
28
  "tsup": "8.1.0",
29
29
  "typescript": "5.4.5",
30
- "vitest": "0.34.6",
30
+ "vitest": "2.0.3",
31
31
  "@leather.io/eslint-config": "0.6.1",
32
- "@leather.io/prettier-config": "0.5.0",
33
- "@leather.io/tsconfig-config": "0.5.0"
32
+ "@leather.io/tsconfig-config": "0.5.1",
33
+ "@leather.io/prettier-config": "0.5.0"
34
34
  },
35
35
  "keywords": [
36
36
  "leather",
package/vitest.config.js CHANGED
@@ -1,5 +1,5 @@
1
- import { defineConfig } from 'vitest/config';
1
+ import { defineProject } from 'vitest/config';
2
2
 
3
3
  import { defaultVitestUnitTestingConfig } from '../../config/vitest-configs';
4
4
 
5
- export default defineConfig({ ...defaultVitestUnitTestingConfig });
5
+ export default defineProject({ ...defaultVitestUnitTestingConfig });