@gardenfi/core 0.2.0-beta.75 → 0.2.0-beta.77

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.
Files changed (299) hide show
  1. package/dist/index.cjs +31 -1
  2. package/dist/index.js +7813 -28
  3. package/package.json +1 -1
  4. package/dist/index10.cjs +0 -1
  5. package/dist/index10.js +0 -112
  6. package/dist/index100.cjs +0 -1
  7. package/dist/index100.js +0 -23
  8. package/dist/index101.cjs +0 -1
  9. package/dist/index101.js +0 -9
  10. package/dist/index102.cjs +0 -1
  11. package/dist/index102.js +0 -35
  12. package/dist/index103.cjs +0 -1
  13. package/dist/index103.js +0 -4
  14. package/dist/index104.cjs +0 -1
  15. package/dist/index104.js +0 -40
  16. package/dist/index105.cjs +0 -1
  17. package/dist/index105.js +0 -31
  18. package/dist/index106.cjs +0 -1
  19. package/dist/index106.js +0 -9
  20. package/dist/index107.cjs +0 -1
  21. package/dist/index107.js +0 -7
  22. package/dist/index108.cjs +0 -1
  23. package/dist/index108.js +0 -13
  24. package/dist/index109.cjs +0 -1
  25. package/dist/index109.js +0 -4
  26. package/dist/index11.cjs +0 -20
  27. package/dist/index11.js +0 -380
  28. package/dist/index110.cjs +0 -1
  29. package/dist/index110.js +0 -60
  30. package/dist/index111.cjs +0 -1
  31. package/dist/index111.js +0 -4
  32. package/dist/index112.cjs +0 -1
  33. package/dist/index112.js +0 -42
  34. package/dist/index113.cjs +0 -1
  35. package/dist/index113.js +0 -45
  36. package/dist/index114.cjs +0 -1
  37. package/dist/index114.js +0 -20
  38. package/dist/index115.cjs +0 -1
  39. package/dist/index115.js +0 -111
  40. package/dist/index116.cjs +0 -1
  41. package/dist/index116.js +0 -23
  42. package/dist/index117.cjs +0 -1
  43. package/dist/index117.js +0 -228
  44. package/dist/index118.cjs +0 -1
  45. package/dist/index118.js +0 -6
  46. package/dist/index119.cjs +0 -1
  47. package/dist/index119.js +0 -160
  48. package/dist/index12.cjs +0 -1
  49. package/dist/index12.js +0 -22
  50. package/dist/index120.cjs +0 -1
  51. package/dist/index120.js +0 -4
  52. package/dist/index121.cjs +0 -1
  53. package/dist/index121.js +0 -75
  54. package/dist/index122.cjs +0 -1
  55. package/dist/index122.js +0 -64
  56. package/dist/index123.cjs +0 -1
  57. package/dist/index123.js +0 -37
  58. package/dist/index124.cjs +0 -1
  59. package/dist/index124.js +0 -7
  60. package/dist/index125.cjs +0 -1
  61. package/dist/index125.js +0 -107
  62. package/dist/index126.cjs +0 -1
  63. package/dist/index126.js +0 -15
  64. package/dist/index127.cjs +0 -1
  65. package/dist/index127.js +0 -35
  66. package/dist/index128.cjs +0 -1
  67. package/dist/index128.js +0 -4
  68. package/dist/index129.cjs +0 -1
  69. package/dist/index129.js +0 -32
  70. package/dist/index13.cjs +0 -1
  71. package/dist/index13.js +0 -396
  72. package/dist/index130.cjs +0 -1
  73. package/dist/index130.js +0 -4
  74. package/dist/index131.cjs +0 -1
  75. package/dist/index131.js +0 -358
  76. package/dist/index132.cjs +0 -1
  77. package/dist/index132.js +0 -241
  78. package/dist/index133.cjs +0 -1
  79. package/dist/index133.js +0 -70
  80. package/dist/index134.cjs +0 -1
  81. package/dist/index134.js +0 -64
  82. package/dist/index135.cjs +0 -1
  83. package/dist/index135.js +0 -14
  84. package/dist/index136.cjs +0 -1
  85. package/dist/index136.js +0 -47
  86. package/dist/index137.cjs +0 -1
  87. package/dist/index137.js +0 -65
  88. package/dist/index138.cjs +0 -1
  89. package/dist/index138.js +0 -21
  90. package/dist/index139.cjs +0 -1
  91. package/dist/index139.js +0 -228
  92. package/dist/index14.cjs +0 -1
  93. package/dist/index14.js +0 -28
  94. package/dist/index140.cjs +0 -1
  95. package/dist/index140.js +0 -5
  96. package/dist/index141.cjs +0 -1
  97. package/dist/index141.js +0 -171
  98. package/dist/index142.cjs +0 -1
  99. package/dist/index142.js +0 -30
  100. package/dist/index143.cjs +0 -1
  101. package/dist/index143.js +0 -23
  102. package/dist/index144.cjs +0 -1
  103. package/dist/index144.js +0 -72
  104. package/dist/index145.cjs +0 -1
  105. package/dist/index145.js +0 -130
  106. package/dist/index146.cjs +0 -1
  107. package/dist/index146.js +0 -9
  108. package/dist/index147.cjs +0 -1
  109. package/dist/index147.js +0 -4
  110. package/dist/index148.cjs +0 -1
  111. package/dist/index148.js +0 -28
  112. package/dist/index149.cjs +0 -1
  113. package/dist/index149.js +0 -4
  114. package/dist/index15.cjs +0 -1
  115. package/dist/index15.js +0 -34
  116. package/dist/index16.cjs +0 -1
  117. package/dist/index16.js +0 -27
  118. package/dist/index17.cjs +0 -1
  119. package/dist/index17.js +0 -33
  120. package/dist/index18.cjs +0 -1
  121. package/dist/index18.js +0 -32
  122. package/dist/index19.cjs +0 -1
  123. package/dist/index19.js +0 -55
  124. package/dist/index2.cjs +0 -1
  125. package/dist/index2.js +0 -412
  126. package/dist/index20.cjs +0 -1
  127. package/dist/index20.js +0 -28
  128. package/dist/index21.cjs +0 -1
  129. package/dist/index21.js +0 -4
  130. package/dist/index22.cjs +0 -1
  131. package/dist/index22.js +0 -140
  132. package/dist/index23.cjs +0 -1
  133. package/dist/index23.js +0 -4
  134. package/dist/index24.cjs +0 -1
  135. package/dist/index24.js +0 -11
  136. package/dist/index25.cjs +0 -1
  137. package/dist/index25.js +0 -11
  138. package/dist/index26.cjs +0 -3
  139. package/dist/index26.js +0 -30
  140. package/dist/index27.cjs +0 -1
  141. package/dist/index27.js +0 -17
  142. package/dist/index28.cjs +0 -2
  143. package/dist/index28.js +0 -27
  144. package/dist/index29.cjs +0 -1
  145. package/dist/index29.js +0 -43
  146. package/dist/index3.cjs +0 -1
  147. package/dist/index3.js +0 -5
  148. package/dist/index30.cjs +0 -1
  149. package/dist/index30.js +0 -201
  150. package/dist/index31.cjs +0 -1
  151. package/dist/index31.js +0 -4
  152. package/dist/index32.cjs +0 -1
  153. package/dist/index32.js +0 -4
  154. package/dist/index33.cjs +0 -1
  155. package/dist/index33.js +0 -4
  156. package/dist/index34.cjs +0 -1
  157. package/dist/index34.js +0 -15
  158. package/dist/index35.cjs +0 -1
  159. package/dist/index35.js +0 -39
  160. package/dist/index36.cjs +0 -1
  161. package/dist/index36.js +0 -44
  162. package/dist/index37.cjs +0 -1
  163. package/dist/index37.js +0 -30
  164. package/dist/index38.cjs +0 -1
  165. package/dist/index38.js +0 -17
  166. package/dist/index39.cjs +0 -1
  167. package/dist/index39.js +0 -26
  168. package/dist/index4.cjs +0 -1
  169. package/dist/index4.js +0 -18
  170. package/dist/index40.cjs +0 -1
  171. package/dist/index40.js +0 -28
  172. package/dist/index41.cjs +0 -1
  173. package/dist/index41.js +0 -57
  174. package/dist/index42.cjs +0 -1
  175. package/dist/index42.js +0 -30
  176. package/dist/index43.cjs +0 -1
  177. package/dist/index43.js +0 -177
  178. package/dist/index44.cjs +0 -1
  179. package/dist/index44.js +0 -4
  180. package/dist/index45.cjs +0 -1
  181. package/dist/index45.js +0 -37
  182. package/dist/index46.cjs +0 -1
  183. package/dist/index46.js +0 -11
  184. package/dist/index47.cjs +0 -1
  185. package/dist/index47.js +0 -15
  186. package/dist/index48.cjs +0 -1
  187. package/dist/index48.js +0 -14
  188. package/dist/index49.cjs +0 -1
  189. package/dist/index49.js +0 -6
  190. package/dist/index5.cjs +0 -1
  191. package/dist/index5.js +0 -99
  192. package/dist/index50.cjs +0 -1
  193. package/dist/index50.js +0 -48
  194. package/dist/index51.cjs +0 -1
  195. package/dist/index51.js +0 -45
  196. package/dist/index52.cjs +0 -1
  197. package/dist/index52.js +0 -174
  198. package/dist/index53.cjs +0 -1
  199. package/dist/index53.js +0 -15
  200. package/dist/index54.cjs +0 -1
  201. package/dist/index54.js +0 -7
  202. package/dist/index55.cjs +0 -1
  203. package/dist/index55.js +0 -19
  204. package/dist/index56.cjs +0 -1
  205. package/dist/index56.js +0 -14
  206. package/dist/index57.cjs +0 -1
  207. package/dist/index57.js +0 -22
  208. package/dist/index58.cjs +0 -1
  209. package/dist/index58.js +0 -34
  210. package/dist/index59.cjs +0 -1
  211. package/dist/index59.js +0 -4
  212. package/dist/index6.cjs +0 -1
  213. package/dist/index6.js +0 -5
  214. package/dist/index60.cjs +0 -6
  215. package/dist/index60.js +0 -949
  216. package/dist/index61.cjs +0 -1
  217. package/dist/index61.js +0 -4
  218. package/dist/index62.cjs +0 -1
  219. package/dist/index62.js +0 -64
  220. package/dist/index63.cjs +0 -1
  221. package/dist/index63.js +0 -35
  222. package/dist/index64.cjs +0 -1
  223. package/dist/index64.js +0 -89
  224. package/dist/index65.cjs +0 -1
  225. package/dist/index65.js +0 -58
  226. package/dist/index66.cjs +0 -2
  227. package/dist/index66.js +0 -62
  228. package/dist/index67.cjs +0 -1
  229. package/dist/index67.js +0 -6
  230. package/dist/index68.cjs +0 -1
  231. package/dist/index68.js +0 -37
  232. package/dist/index69.cjs +0 -1
  233. package/dist/index69.js +0 -130
  234. package/dist/index7.cjs +0 -1
  235. package/dist/index7.js +0 -76
  236. package/dist/index70.cjs +0 -2
  237. package/dist/index70.js +0 -45
  238. package/dist/index71.cjs +0 -1
  239. package/dist/index71.js +0 -11
  240. package/dist/index72.cjs +0 -1
  241. package/dist/index72.js +0 -13
  242. package/dist/index73.cjs +0 -1
  243. package/dist/index73.js +0 -14
  244. package/dist/index74.cjs +0 -1
  245. package/dist/index74.js +0 -16
  246. package/dist/index75.cjs +0 -1
  247. package/dist/index75.js +0 -9
  248. package/dist/index76.cjs +0 -1
  249. package/dist/index76.js +0 -20
  250. package/dist/index77.cjs +0 -1
  251. package/dist/index77.js +0 -81
  252. package/dist/index78.cjs +0 -1
  253. package/dist/index78.js +0 -17
  254. package/dist/index79.cjs +0 -1
  255. package/dist/index79.js +0 -21
  256. package/dist/index8.cjs +0 -1
  257. package/dist/index8.js +0 -61
  258. package/dist/index80.cjs +0 -1
  259. package/dist/index80.js +0 -24
  260. package/dist/index81.cjs +0 -1
  261. package/dist/index81.js +0 -16
  262. package/dist/index82.cjs +0 -1
  263. package/dist/index82.js +0 -9
  264. package/dist/index83.cjs +0 -1
  265. package/dist/index83.js +0 -4
  266. package/dist/index84.cjs +0 -1
  267. package/dist/index84.js +0 -4
  268. package/dist/index85.cjs +0 -2
  269. package/dist/index85.js +0 -37
  270. package/dist/index86.cjs +0 -1
  271. package/dist/index86.js +0 -8
  272. package/dist/index87.cjs +0 -1
  273. package/dist/index87.js +0 -22
  274. package/dist/index88.cjs +0 -1
  275. package/dist/index88.js +0 -37
  276. package/dist/index89.cjs +0 -1
  277. package/dist/index89.js +0 -369
  278. package/dist/index9.cjs +0 -1
  279. package/dist/index9.js +0 -63
  280. package/dist/index90.cjs +0 -1
  281. package/dist/index90.js +0 -23
  282. package/dist/index91.cjs +0 -1
  283. package/dist/index91.js +0 -58
  284. package/dist/index92.cjs +0 -1
  285. package/dist/index92.js +0 -5
  286. package/dist/index93.cjs +0 -1
  287. package/dist/index93.js +0 -51
  288. package/dist/index94.cjs +0 -1
  289. package/dist/index94.js +0 -28
  290. package/dist/index95.cjs +0 -1
  291. package/dist/index95.js +0 -4
  292. package/dist/index96.cjs +0 -1
  293. package/dist/index96.js +0 -4
  294. package/dist/index97.cjs +0 -1
  295. package/dist/index97.js +0 -15
  296. package/dist/index98.cjs +0 -1
  297. package/dist/index98.js +0 -9
  298. package/dist/index99.cjs +0 -1
  299. package/dist/index99.js +0 -115
package/dist/index70.js DELETED
@@ -1,45 +0,0 @@
1
- import { BaseError as t } from "./index66.js";
2
- function i(n) {
3
- const r = Object.entries(n).map(([a, e]) => e === void 0 || e === !1 ? null : [a, e]).filter(Boolean), o = r.reduce((a, [e]) => Math.max(a, e.length), 0);
4
- return r.map(([a, e]) => ` ${`${a}:`.padEnd(o + 1)} ${e}`).join(`
5
- `);
6
- }
7
- class c extends t {
8
- constructor({ v: r }) {
9
- super(`Invalid \`v\` value "${r}". Expected 27 or 28.`, {
10
- name: "InvalidLegacyVError"
11
- });
12
- }
13
- }
14
- class d extends t {
15
- constructor({ transaction: r }) {
16
- super("Cannot infer a transaction type from provided transaction.", {
17
- metaMessages: [
18
- "Provided Transaction:",
19
- "{",
20
- i(r),
21
- "}",
22
- "",
23
- "To infer the type, either provide:",
24
- "- a `type` to the Transaction, or",
25
- "- an EIP-1559 Transaction with `maxFeePerGas`, or",
26
- "- an EIP-2930 Transaction with `gasPrice` & `accessList`, or",
27
- "- an EIP-4844 Transaction with `blobs`, `blobVersionedHashes`, `sidecars`, or",
28
- "- an EIP-7702 Transaction with `authorizationList`, or",
29
- "- a Legacy Transaction with `gasPrice`"
30
- ],
31
- name: "InvalidSerializableTransactionError"
32
- });
33
- }
34
- }
35
- class l extends t {
36
- constructor({ storageKey: r }) {
37
- super(`Size for storage key "${r}" is invalid. Expected 32 bytes. Got ${Math.floor((r.length - 2) / 2)} bytes.`, { name: "InvalidStorageKeySizeError" });
38
- }
39
- }
40
- export {
41
- c as InvalidLegacyVError,
42
- d as InvalidSerializableTransactionError,
43
- l as InvalidStorageKeySizeError,
44
- i as prettyPrint
45
- };
package/dist/index71.cjs DELETED
@@ -1 +0,0 @@
1
- "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const i=require("./index65.cjs"),l=require("./index50.cjs");function c(o){const{kzg:s}=o,n=o.to??(typeof o.blobs[0]=="string"?"hex":"bytes"),e=typeof o.blobs[0]=="string"?o.blobs.map(t=>i.hexToBytes(t)):o.blobs,b=[];for(const t of e)b.push(Uint8Array.from(s.blobToKzgCommitment(t)));return n==="bytes"?b:b.map(t=>l.bytesToHex(t))}exports.blobsToCommitments=c;
package/dist/index71.js DELETED
@@ -1,11 +0,0 @@
1
- import { hexToBytes as i } from "./index65.js";
2
- import { bytesToHex as f } from "./index50.js";
3
- function y(o) {
4
- const { kzg: s } = o, n = o.to ?? (typeof o.blobs[0] == "string" ? "hex" : "bytes"), m = typeof o.blobs[0] == "string" ? o.blobs.map((t) => i(t)) : o.blobs, b = [];
5
- for (const t of m)
6
- b.push(Uint8Array.from(s.blobToKzgCommitment(t)));
7
- return n === "bytes" ? b : b.map((t) => f(t));
8
- }
9
- export {
10
- y as blobsToCommitments
11
- };
package/dist/index72.cjs DELETED
@@ -1 +0,0 @@
1
- "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const b=require("./index65.cjs"),y=require("./index50.cjs");function f(t){const{kzg:c}=t,e=t.to??(typeof t.blobs[0]=="string"?"hex":"bytes"),n=typeof t.blobs[0]=="string"?t.blobs.map(o=>b.hexToBytes(o)):t.blobs,i=typeof t.commitments[0]=="string"?t.commitments.map(o=>b.hexToBytes(o)):t.commitments,s=[];for(let o=0;o<n.length;o++){const l=n[o],m=i[o];s.push(Uint8Array.from(c.computeBlobKzgProof(l,m)))}return e==="bytes"?s:s.map(o=>y.bytesToHex(o))}exports.blobsToProofs=f;
package/dist/index72.js DELETED
@@ -1,13 +0,0 @@
1
- import { hexToBytes as b } from "./index65.js";
2
- import { bytesToHex as y } from "./index50.js";
3
- function h(t) {
4
- const { kzg: m } = t, c = t.to ?? (typeof t.blobs[0] == "string" ? "hex" : "bytes"), s = typeof t.blobs[0] == "string" ? t.blobs.map((o) => b(o)) : t.blobs, i = typeof t.commitments[0] == "string" ? t.commitments.map((o) => b(o)) : t.commitments, n = [];
5
- for (let o = 0; o < s.length; o++) {
6
- const f = s[o], l = i[o];
7
- n.push(Uint8Array.from(m.computeBlobKzgProof(f, l)));
8
- }
9
- return c === "bytes" ? n : n.map((o) => y(o));
10
- }
11
- export {
12
- h as blobsToProofs
13
- };
package/dist/index73.cjs DELETED
@@ -1 +0,0 @@
1
- "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const i=require("./index101.cjs");function c(o){const{commitments:e,version:s}=o,n=o.to??(typeof e[0]=="string"?"hex":"bytes"),t=[];for(const m of e)t.push(i.commitmentToVersionedHash({commitment:m,to:n,version:s}));return t}exports.commitmentsToVersionedHashes=c;
package/dist/index73.js DELETED
@@ -1,14 +0,0 @@
1
- import { commitmentToVersionedHash as i } from "./index101.js";
2
- function r(o) {
3
- const { commitments: t, version: n } = o, e = o.to ?? (typeof t[0] == "string" ? "hex" : "bytes"), s = [];
4
- for (const m of t)
5
- s.push(i({
6
- commitment: m,
7
- to: e,
8
- version: n
9
- }));
10
- return s;
11
- }
12
- export {
13
- r as commitmentsToVersionedHashes
14
- };
package/dist/index74.cjs DELETED
@@ -1 +0,0 @@
1
- "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const r=require("./index71.cjs"),m=require("./index72.cjs"),u=require("./index102.cjs");function f(t){const{data:i,kzg:n,to:b}=t,s=t.blobs??u.toBlobs({data:i,to:b}),e=t.commitments??r.blobsToCommitments({blobs:s,kzg:n,to:b}),l=t.proofs??m.blobsToProofs({blobs:s,commitments:e,kzg:n,to:b}),c=[];for(let o=0;o<s.length;o++)c.push({blob:s[o],commitment:e[o],proof:l[o]});return c}exports.toBlobSidecars=f;
package/dist/index74.js DELETED
@@ -1,16 +0,0 @@
1
- import { blobsToCommitments as f } from "./index71.js";
2
- import { blobsToProofs as l } from "./index72.js";
3
- import { toBlobs as p } from "./index102.js";
4
- function k(t) {
5
- const { data: i, kzg: n, to: m } = t, s = t.blobs ?? p({ data: i, to: m }), b = t.commitments ?? f({ blobs: s, kzg: n, to: m }), r = t.proofs ?? l({ blobs: s, commitments: b, kzg: n, to: m }), c = [];
6
- for (let o = 0; o < s.length; o++)
7
- c.push({
8
- blob: s[o],
9
- commitment: b[o],
10
- proof: r[o]
11
- });
12
- return c;
13
- }
14
- export {
15
- k as toBlobSidecars
16
- };
package/dist/index75.cjs DELETED
@@ -1 +0,0 @@
1
- "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});function g(e,{dir:i="left"}={}){let t=typeof e=="string"?e.replace("0x",""):e,n=0;for(let l=0;l<t.length-1&&t[i==="left"?l:t.length-l-1].toString()==="0";l++)n++;return t=i==="left"?t.slice(n):t.slice(0,t.length-n),typeof e=="string"?(t.length===1&&i==="right"&&(t=`${t}0`),`0x${t.length%2===1?`0${t}`:t}`):t}exports.trim=g;
package/dist/index75.js DELETED
@@ -1,9 +0,0 @@
1
- function f(e, { dir: n = "left" } = {}) {
2
- let t = typeof e == "string" ? e.replace("0x", "") : e, i = 0;
3
- for (let l = 0; l < t.length - 1 && t[n === "left" ? l : t.length - l - 1].toString() === "0"; l++)
4
- i++;
5
- return t = n === "left" ? t.slice(i) : t.slice(0, t.length - i), typeof e == "string" ? (t.length === 1 && n === "right" && (t = `${t}0`), `0x${t.length % 2 === 1 ? `0${t}` : t}`) : t;
6
- }
7
- export {
8
- f as trim
9
- };
package/dist/index76.cjs DELETED
@@ -1 +0,0 @@
1
- "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const i=require("./index50.cjs"),c=require("./index52.cjs");function u(t){if(!t||t.length===0)return[];const e=[];for(const o of t){const{contractAddress:n,chainId:s,nonce:r,...a}=o;e.push([i.toHex(s),n,r?i.toHex(r):"0x",...c.toYParitySignatureArray({},a)])}return e}exports.serializeAuthorizationList=u;
package/dist/index76.js DELETED
@@ -1,20 +0,0 @@
1
- import { toHex as n } from "./index50.js";
2
- import { toYParitySignatureArray as c } from "./index52.js";
3
- function d(r) {
4
- if (!r || r.length === 0)
5
- return [];
6
- const t = [];
7
- for (const i of r) {
8
- const { contractAddress: e, chainId: s, nonce: o, ...a } = i;
9
- t.push([
10
- n(s),
11
- e,
12
- o ? n(o) : "0x",
13
- ...c({}, a)
14
- ]);
15
- }
16
- return t;
17
- }
18
- export {
19
- d as serializeAuthorizationList
20
- };
package/dist/index77.cjs DELETED
@@ -1 +0,0 @@
1
- "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const E=require("./index103.cjs"),w=require("./index83.cjs"),t=require("./index47.cjs"),P=require("./index66.cjs"),h=require("./index104.cjs"),d=require("./index82.cjs"),n=require("./index85.cjs"),c=require("./index48.cjs"),I=require("./index54.cjs"),u=require("./index105.cjs"),l=require("./index39.cjs");function m(o){const{authorizationList:e}=o;if(e)for(const s of e){const{contractAddress:r,chainId:i}=s;if(!c.isAddress(r))throw new t.InvalidAddressError({address:r});if(i<=0)throw new d.InvalidChainIdError({chainId:i})}f(o)}function T(o){const{blobVersionedHashes:e}=o;if(e){if(e.length===0)throw new h.EmptyBlobError;for(const s of e){const r=I.size(s),i=l.hexToNumber(u.slice(s,0,1));if(r!==32)throw new h.InvalidVersionedHashSizeError({hash:s,size:r});if(i!==E.versionedHashVersionKzg)throw new h.InvalidVersionedHashVersionError({hash:s,version:i})}}f(o)}function f(o){const{chainId:e,maxPriorityFeePerGas:s,maxFeePerGas:r,to:i}=o;if(e<=0)throw new d.InvalidChainIdError({chainId:e});if(i&&!c.isAddress(i))throw new t.InvalidAddressError({address:i});if(r&&r>w.maxUint256)throw new n.FeeCapTooHighError({maxFeePerGas:r});if(s&&r&&s>r)throw new n.TipAboveFeeCapError({maxFeePerGas:r,maxPriorityFeePerGas:s})}function x(o){const{chainId:e,maxPriorityFeePerGas:s,gasPrice:r,maxFeePerGas:i,to:a}=o;if(e<=0)throw new d.InvalidChainIdError({chainId:e});if(a&&!c.isAddress(a))throw new t.InvalidAddressError({address:a});if(s||i)throw new P.BaseError("`maxFeePerGas`/`maxPriorityFeePerGas` is not a valid EIP-2930 Transaction attribute.");if(r&&r>w.maxUint256)throw new n.FeeCapTooHighError({maxFeePerGas:r})}function v(o){const{chainId:e,maxPriorityFeePerGas:s,gasPrice:r,maxFeePerGas:i,to:a}=o;if(a&&!c.isAddress(a))throw new t.InvalidAddressError({address:a});if(typeof e<"u"&&e<=0)throw new d.InvalidChainIdError({chainId:e});if(s||i)throw new P.BaseError("`maxFeePerGas`/`maxPriorityFeePerGas` is not a valid Legacy Transaction attribute.");if(r&&r>w.maxUint256)throw new n.FeeCapTooHighError({maxFeePerGas:r})}exports.assertTransactionEIP1559=f;exports.assertTransactionEIP2930=x;exports.assertTransactionEIP4844=T;exports.assertTransactionEIP7702=m;exports.assertTransactionLegacy=v;
package/dist/index77.js DELETED
@@ -1,81 +0,0 @@
1
- import { versionedHashVersionKzg as d } from "./index103.js";
2
- import { maxUint256 as m } from "./index83.js";
3
- import { InvalidAddressError as s } from "./index47.js";
4
- import { BaseError as h } from "./index66.js";
5
- import { EmptyBlobError as P, InvalidVersionedHashSizeError as p, InvalidVersionedHashVersionError as x } from "./index104.js";
6
- import { InvalidChainIdError as n } from "./index82.js";
7
- import { FeeCapTooHighError as w, TipAboveFeeCapError as E } from "./index85.js";
8
- import { isAddress as f } from "./index48.js";
9
- import { size as F } from "./index54.js";
10
- import { slice as I } from "./index105.js";
11
- import { hexToNumber as G } from "./index39.js";
12
- function C(t) {
13
- const { authorizationList: e } = t;
14
- if (e)
15
- for (const o of e) {
16
- const { contractAddress: r, chainId: i } = o;
17
- if (!f(r))
18
- throw new s({ address: r });
19
- if (i <= 0)
20
- throw new n({ chainId: i });
21
- }
22
- c(t);
23
- }
24
- function L(t) {
25
- const { blobVersionedHashes: e } = t;
26
- if (e) {
27
- if (e.length === 0)
28
- throw new P();
29
- for (const o of e) {
30
- const r = F(o), i = G(I(o, 0, 1));
31
- if (r !== 32)
32
- throw new p({ hash: o, size: r });
33
- if (i !== d)
34
- throw new x({
35
- hash: o,
36
- version: i
37
- });
38
- }
39
- }
40
- c(t);
41
- }
42
- function c(t) {
43
- const { chainId: e, maxPriorityFeePerGas: o, maxFeePerGas: r, to: i } = t;
44
- if (e <= 0)
45
- throw new n({ chainId: e });
46
- if (i && !f(i))
47
- throw new s({ address: i });
48
- if (r && r > m)
49
- throw new w({ maxFeePerGas: r });
50
- if (o && r && o > r)
51
- throw new E({ maxFeePerGas: r, maxPriorityFeePerGas: o });
52
- }
53
- function B(t) {
54
- const { chainId: e, maxPriorityFeePerGas: o, gasPrice: r, maxFeePerGas: i, to: a } = t;
55
- if (e <= 0)
56
- throw new n({ chainId: e });
57
- if (a && !f(a))
58
- throw new s({ address: a });
59
- if (o || i)
60
- throw new h("`maxFeePerGas`/`maxPriorityFeePerGas` is not a valid EIP-2930 Transaction attribute.");
61
- if (r && r > m)
62
- throw new w({ maxFeePerGas: r });
63
- }
64
- function K(t) {
65
- const { chainId: e, maxPriorityFeePerGas: o, gasPrice: r, maxFeePerGas: i, to: a } = t;
66
- if (a && !f(a))
67
- throw new s({ address: a });
68
- if (typeof e < "u" && e <= 0)
69
- throw new n({ chainId: e });
70
- if (o || i)
71
- throw new h("`maxFeePerGas`/`maxPriorityFeePerGas` is not a valid Legacy Transaction attribute.");
72
- if (r && r > m)
73
- throw new w({ maxFeePerGas: r });
74
- }
75
- export {
76
- c as assertTransactionEIP1559,
77
- B as assertTransactionEIP2930,
78
- L as assertTransactionEIP4844,
79
- C as assertTransactionEIP7702,
80
- K as assertTransactionLegacy
81
- };
package/dist/index78.cjs DELETED
@@ -1 +0,0 @@
1
- "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const i=require("./index70.cjs");function f(e){if(e.type)return e.type;if(typeof e.authorizationList<"u")return"eip7702";if(typeof e.blobs<"u"||typeof e.blobVersionedHashes<"u"||typeof e.maxFeePerBlobGas<"u"||typeof e.sidecars<"u")return"eip4844";if(typeof e.maxFeePerGas<"u"||typeof e.maxPriorityFeePerGas<"u")return"eip1559";if(typeof e.gasPrice<"u")return typeof e.accessList<"u"?"eip2930":"legacy";throw new i.InvalidSerializableTransactionError({transaction:e})}exports.getTransactionType=f;
package/dist/index78.js DELETED
@@ -1,17 +0,0 @@
1
- import { InvalidSerializableTransactionError as f } from "./index70.js";
2
- function d(e) {
3
- if (e.type)
4
- return e.type;
5
- if (typeof e.authorizationList < "u")
6
- return "eip7702";
7
- if (typeof e.blobs < "u" || typeof e.blobVersionedHashes < "u" || typeof e.maxFeePerBlobGas < "u" || typeof e.sidecars < "u")
8
- return "eip4844";
9
- if (typeof e.maxFeePerGas < "u" || typeof e.maxPriorityFeePerGas < "u")
10
- return "eip1559";
11
- if (typeof e.gasPrice < "u")
12
- return typeof e.accessList < "u" ? "eip2930" : "legacy";
13
- throw new f({ transaction: e });
14
- }
15
- export {
16
- d as getTransactionType
17
- };
package/dist/index79.cjs DELETED
@@ -1 +0,0 @@
1
- "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const o=require("./index47.cjs"),d=require("./index70.cjs"),l=require("./index48.cjs");function a(e){if(!e||e.length===0)return[];const n=[];for(let t=0;t<e.length;t++){const{address:i,storageKeys:r}=e[t];for(let s=0;s<r.length;s++)if(r[s].length-2!==64)throw new d.InvalidStorageKeySizeError({storageKey:r[s]});if(!l.isAddress(i,{strict:!1}))throw new o.InvalidAddressError({address:i});n.push([i,r])}return n}exports.serializeAccessList=a;
package/dist/index79.js DELETED
@@ -1,21 +0,0 @@
1
- import { InvalidAddressError as s } from "./index47.js";
2
- import { InvalidStorageKeySizeError as l } from "./index70.js";
3
- import { isAddress as f } from "./index48.js";
4
- function a(r) {
5
- if (!r || r.length === 0)
6
- return [];
7
- const n = [];
8
- for (let o = 0; o < r.length; o++) {
9
- const { address: i, storageKeys: e } = r[o];
10
- for (let t = 0; t < e.length; t++)
11
- if (e[t].length - 2 !== 64)
12
- throw new l({ storageKey: e[t] });
13
- if (!f(i, { strict: !1 }))
14
- throw new s({ address: i });
15
- n.push([i, e]);
16
- }
17
- return n;
18
- }
19
- export {
20
- a as serializeAccessList
21
- };
package/dist/index8.cjs DELETED
@@ -1 +0,0 @@
1
- "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const r=require("@catalogfi/utils"),i=require("viem"),g=require("./index14.cjs"),f=require("tiny-secp256k1"),y=require("@gardenfi/utils");function m(s){const e=Object.create(null,{[Symbol.toStringTag]:{value:"Module"}});if(s){for(const t in s)if(t!=="default"){const n=Object.getOwnPropertyDescriptor(s,t);Object.defineProperty(e,t,n.get?n:{enumerable:!0,get:()=>s[t]})}}return e.default=s,Object.freeze(e)}const p=m(f);class a{constructor(e){this.privKey=e}static fromPrivKey(e){return new a(r.trim0x(e))}static async fromWalletClient(e){if(!e.account)return r.Err("No account found");try{const t=await e.signTypedData({account:e.account,types:{EIP712Domain:[{name:"name",type:"string"},{name:"version",type:"string"}],Data:[{name:"Message",type:"string"},{name:"Version",type:"string"},{name:"Nonce",type:"uint256"}]},domain:{name:"WBTC GARDEN",version:"1"},primaryType:"Data",message:{Message:"Initialize your account",Version:"1.0.2",Nonce:1n}});return r.Ok(new a(r.trim0x(i.sha256(t))))}catch(t){return r.Err("Failed to initialize: "+t)}}getMasterPrivKey(){return this.privKey}generateSecret(e){const t=this.signMessage(e),n=i.sha256(y.with0x(t)),o=i.sha256(n);return r.Ok({secret:n,secretHash:o})}signMessage(e){const t=g(p),n="Garden.fi"+e.toString(),o=Buffer.from(n,"utf8"),u=i.sha256(o),c=Buffer.from(r.trim0x(this.privKey),"hex");if(c.length!==32)throw new Error("Invalid private key length. Expected 32 bytes.");return t.fromPrivateKey(c).sign(Buffer.from(r.trim0x(u),"hex")).toString("hex")}}exports.SecretManager=a;
package/dist/index8.js DELETED
@@ -1,61 +0,0 @@
1
- import { trim0x as n, Err as c, Ok as m } from "@catalogfi/utils";
2
- import { sha256 as s } from "viem";
3
- import u from "./index14.js";
4
- import * as f from "tiny-secp256k1";
5
- import { with0x as y } from "@gardenfi/utils";
6
- class a {
7
- constructor(e) {
8
- this.privKey = e;
9
- }
10
- static fromPrivKey(e) {
11
- return new a(n(e));
12
- }
13
- static async fromWalletClient(e) {
14
- if (!e.account) return c("No account found");
15
- try {
16
- const r = await e.signTypedData({
17
- account: e.account,
18
- types: {
19
- EIP712Domain: [
20
- { name: "name", type: "string" },
21
- { name: "version", type: "string" }
22
- ],
23
- Data: [
24
- { name: "Message", type: "string" },
25
- { name: "Version", type: "string" },
26
- { name: "Nonce", type: "uint256" }
27
- ]
28
- },
29
- domain: {
30
- name: "WBTC GARDEN",
31
- version: "1"
32
- },
33
- primaryType: "Data",
34
- message: {
35
- Message: "Initialize your account",
36
- Version: "1.0.2",
37
- Nonce: 1n
38
- }
39
- });
40
- return m(new a(n(s(r))));
41
- } catch (r) {
42
- return c("Failed to initialize: " + r);
43
- }
44
- }
45
- getMasterPrivKey() {
46
- return this.privKey;
47
- }
48
- generateSecret(e) {
49
- const r = this.signMessage(e), t = s(y(r)), i = s(t);
50
- return m({ secret: t, secretHash: i });
51
- }
52
- signMessage(e) {
53
- const r = u(f), t = "Garden.fi" + e.toString(), i = Buffer.from(t, "utf8"), g = s(i), o = Buffer.from(n(this.privKey), "hex");
54
- if (o.length !== 32)
55
- throw new Error("Invalid private key length. Expected 32 bytes.");
56
- return r.fromPrivateKey(o).sign(Buffer.from(n(g), "hex")).toString("hex");
57
- }
58
- }
59
- export {
60
- a as SecretManager
61
- };
package/dist/index80.cjs DELETED
@@ -1 +0,0 @@
1
- "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});class i extends Map{constructor(e){super(),Object.defineProperty(this,"maxSize",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),this.maxSize=e}get(e){const t=super.get(e);return super.has(e)&&t!==void 0&&(this.delete(e),super.set(e,t)),t}set(e,t){if(super.set(e,t),this.maxSize&&this.size>this.maxSize){const s=this.keys().next().value;s&&this.delete(s)}return this}}exports.LruMap=i;
package/dist/index80.js DELETED
@@ -1,24 +0,0 @@
1
- class r extends Map {
2
- constructor(e) {
3
- super(), Object.defineProperty(this, "maxSize", {
4
- enumerable: !0,
5
- configurable: !0,
6
- writable: !0,
7
- value: void 0
8
- }), this.maxSize = e;
9
- }
10
- get(e) {
11
- const t = super.get(e);
12
- return super.has(e) && t !== void 0 && (this.delete(e), super.set(e, t)), t;
13
- }
14
- set(e, t) {
15
- if (super.set(e, t), this.maxSize && this.size > this.maxSize) {
16
- const s = this.keys().next().value;
17
- s && this.delete(s);
18
- }
19
- return this;
20
- }
21
- }
22
- export {
23
- r as LruMap
24
- };
package/dist/index81.cjs DELETED
@@ -1 +0,0 @@
1
- "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const i=require("./index65.cjs"),a=require("./index106.cjs"),f=require("./index80.cjs"),o=new f.LruMap(8192);function k(t,r){if(o.has(`${t}.${r}`))return o.get(`${t}.${r}`);const c=t.substring(2).toLowerCase(),n=a.keccak256(i.stringToBytes(c)),s=c.split("");for(let e=0;e<40;e+=2)n[e>>1]>>4>=8&&s[e]&&(s[e]=s[e].toUpperCase()),(n[e>>1]&15)>=8&&s[e+1]&&(s[e+1]=s[e+1].toUpperCase());const u=`0x${s.join("")}`;return o.set(`${t}.${r}`,u),u}exports.checksumAddress=k;
package/dist/index81.js DELETED
@@ -1,16 +0,0 @@
1
- import { stringToBytes as p } from "./index65.js";
2
- import { keccak256 as f } from "./index106.js";
3
- import { LruMap as m } from "./index80.js";
4
- const r = /* @__PURE__ */ new m(8192);
5
- function a(s, o) {
6
- if (r.has(`${s}.${o}`))
7
- return r.get(`${s}.${o}`);
8
- const c = s.substring(2).toLowerCase(), n = f(p(c)), e = c.split("");
9
- for (let t = 0; t < 40; t += 2)
10
- n[t >> 1] >> 4 >= 8 && e[t] && (e[t] = e[t].toUpperCase()), (n[t >> 1] & 15) >= 8 && e[t + 1] && (e[t + 1] = e[t + 1].toUpperCase());
11
- const i = `0x${e.join("")}`;
12
- return r.set(`${s}.${o}`, i), i;
13
- }
14
- export {
15
- a as checksumAddress
16
- };
package/dist/index82.cjs DELETED
@@ -1 +0,0 @@
1
- "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("./index66.cjs");class i extends e.BaseError{constructor({chainId:r}){super(typeof r=="number"?`Chain ID "${r}" is invalid.`:"Chain ID is invalid.",{name:"InvalidChainIdError"})}}exports.InvalidChainIdError=i;
package/dist/index82.js DELETED
@@ -1,9 +0,0 @@
1
- import { BaseError as i } from "./index66.js";
2
- class o extends i {
3
- constructor({ chainId: r }) {
4
- super(typeof r == "number" ? `Chain ID "${r}" is invalid.` : "Chain ID is invalid.", { name: "InvalidChainIdError" });
5
- }
6
- }
7
- export {
8
- o as InvalidChainIdError
9
- };
package/dist/index83.cjs DELETED
@@ -1 +0,0 @@
1
- "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const t=2n**256n-1n;exports.maxUint256=t;
package/dist/index83.js DELETED
@@ -1,4 +0,0 @@
1
- const n = 2n ** 256n - 1n;
2
- export {
3
- n as maxUint256
4
- };
package/dist/index84.cjs DELETED
@@ -1 +0,0 @@
1
- "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e="2.21.30";exports.version=e;
package/dist/index84.js DELETED
@@ -1,4 +0,0 @@
1
- const o = "2.21.30";
2
- export {
3
- o as version
4
- };
package/dist/index85.cjs DELETED
@@ -1,2 +0,0 @@
1
- "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const a=require("./index86.cjs"),t=require("./index66.cjs");class i extends t.BaseError{constructor({cause:r,maxFeePerGas:e}={}){super(`The fee cap (\`maxFeePerGas\`${e?` = ${a.formatGwei(e)} gwei`:""}) cannot be higher than the maximum allowed value (2^256-1).`,{cause:r,name:"FeeCapTooHighError"})}}Object.defineProperty(i,"nodeMessage",{enumerable:!0,configurable:!0,writable:!0,value:/max fee per gas higher than 2\^256-1|fee cap higher than 2\^256-1/});class n extends t.BaseError{constructor({cause:r,maxPriorityFeePerGas:e,maxFeePerGas:o}={}){super([`The provided tip (\`maxPriorityFeePerGas\`${e?` = ${a.formatGwei(e)} gwei`:""}) cannot be higher than the fee cap (\`maxFeePerGas\`${o?` = ${a.formatGwei(o)} gwei`:""}).`].join(`
2
- `),{cause:r,name:"TipAboveFeeCapError"})}}Object.defineProperty(n,"nodeMessage",{enumerable:!0,configurable:!0,writable:!0,value:/max priority fee per gas higher than max fee per gas|tip higher than fee cap/});exports.FeeCapTooHighError=i;exports.TipAboveFeeCapError=n;
package/dist/index85.js DELETED
@@ -1,37 +0,0 @@
1
- import { formatGwei as a } from "./index86.js";
2
- import { BaseError as o } from "./index66.js";
3
- class n extends o {
4
- constructor({ cause: r, maxFeePerGas: e } = {}) {
5
- super(`The fee cap (\`maxFeePerGas\`${e ? ` = ${a(e)} gwei` : ""}) cannot be higher than the maximum allowed value (2^256-1).`, {
6
- cause: r,
7
- name: "FeeCapTooHighError"
8
- });
9
- }
10
- }
11
- Object.defineProperty(n, "nodeMessage", {
12
- enumerable: !0,
13
- configurable: !0,
14
- writable: !0,
15
- value: /max fee per gas higher than 2\^256-1|fee cap higher than 2\^256-1/
16
- });
17
- class h extends o {
18
- constructor({ cause: r, maxPriorityFeePerGas: e, maxFeePerGas: t } = {}) {
19
- super([
20
- `The provided tip (\`maxPriorityFeePerGas\`${e ? ` = ${a(e)} gwei` : ""}) cannot be higher than the fee cap (\`maxFeePerGas\`${t ? ` = ${a(t)} gwei` : ""}).`
21
- ].join(`
22
- `), {
23
- cause: r,
24
- name: "TipAboveFeeCapError"
25
- });
26
- }
27
- }
28
- Object.defineProperty(h, "nodeMessage", {
29
- enumerable: !0,
30
- configurable: !0,
31
- writable: !0,
32
- value: /max priority fee per gas higher than max fee per gas|tip higher than fee cap/
33
- });
34
- export {
35
- n as FeeCapTooHighError,
36
- h as TipAboveFeeCapError
37
- };
package/dist/index86.cjs DELETED
@@ -1 +0,0 @@
1
- "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const i=require("./index107.cjs"),r=require("./index108.cjs");function n(t,e="wei"){return r.formatUnits(t,i.gweiUnits[e])}exports.formatGwei=n;
package/dist/index86.js DELETED
@@ -1,8 +0,0 @@
1
- import { gweiUnits as i } from "./index107.js";
2
- import { formatUnits as o } from "./index108.js";
3
- function f(r, t = "wei") {
4
- return o(r, i[t]);
5
- }
6
- export {
7
- f as formatGwei
8
- };
package/dist/index87.cjs DELETED
@@ -1 +0,0 @@
1
- "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const r=require("./index109.cjs");typeof Object.create=="function"?r.__module.exports=function(e,t){t&&(e.super_=t,e.prototype=Object.create(t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}))}:r.__module.exports=function(e,t){if(t){e.super_=t;var o=function(){};o.prototype=t.prototype,e.prototype=new o,e.prototype.constructor=e}};var n=r.__module.exports;exports.inherits_browserExports=n;
package/dist/index87.js DELETED
@@ -1,22 +0,0 @@
1
- import { __module as o } from "./index109.js";
2
- typeof Object.create == "function" ? o.exports = function(e, t) {
3
- t && (e.super_ = t, e.prototype = Object.create(t.prototype, {
4
- constructor: {
5
- value: e,
6
- enumerable: !1,
7
- writable: !0,
8
- configurable: !0
9
- }
10
- }));
11
- } : o.exports = function(e, t) {
12
- if (t) {
13
- e.super_ = t;
14
- var r = function() {
15
- };
16
- r.prototype = t.prototype, e.prototype = new r(), e.prototype.constructor = e;
17
- }
18
- };
19
- var p = o.exports;
20
- export {
21
- p as i
22
- };
package/dist/index88.cjs DELETED
@@ -1 +0,0 @@
1
- "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const o=require("./index87.cjs"),u=require("./index110.cjs"),l=require("./index45.cjs");var v=o.inherits_browserExports,_=u.hashBase,k=l.safeBufferExports.Buffer,p=new Array(16);function n(){_.call(this,64),this._a=1732584193,this._b=4023233417,this._c=2562383102,this._d=271733878}v(n,_);n.prototype._update=function(){for(var a=p,i=0;i<16;++i)a[i]=this._block.readInt32LE(i*4);var e=this._a,t=this._b,f=this._c,x=this._d;e=s(e,t,f,x,a[0],3614090360,7),x=s(x,e,t,f,a[1],3905402710,12),f=s(f,x,e,t,a[2],606105819,17),t=s(t,f,x,e,a[3],3250441966,22),e=s(e,t,f,x,a[4],4118548399,7),x=s(x,e,t,f,a[5],1200080426,12),f=s(f,x,e,t,a[6],2821735955,17),t=s(t,f,x,e,a[7],4249261313,22),e=s(e,t,f,x,a[8],1770035416,7),x=s(x,e,t,f,a[9],2336552879,12),f=s(f,x,e,t,a[10],4294925233,17),t=s(t,f,x,e,a[11],2304563134,22),e=s(e,t,f,x,a[12],1804603682,7),x=s(x,e,t,f,a[13],4254626195,12),f=s(f,x,e,t,a[14],2792965006,17),t=s(t,f,x,e,a[15],1236535329,22),e=c(e,t,f,x,a[1],4129170786,5),x=c(x,e,t,f,a[6],3225465664,9),f=c(f,x,e,t,a[11],643717713,14),t=c(t,f,x,e,a[0],3921069994,20),e=c(e,t,f,x,a[5],3593408605,5),x=c(x,e,t,f,a[10],38016083,9),f=c(f,x,e,t,a[15],3634488961,14),t=c(t,f,x,e,a[4],3889429448,20),e=c(e,t,f,x,a[9],568446438,5),x=c(x,e,t,f,a[14],3275163606,9),f=c(f,x,e,t,a[3],4107603335,14),t=c(t,f,x,e,a[8],1163531501,20),e=c(e,t,f,x,a[13],2850285829,5),x=c(x,e,t,f,a[2],4243563512,9),f=c(f,x,e,t,a[7],1735328473,14),t=c(t,f,x,e,a[12],2368359562,20),e=r(e,t,f,x,a[5],4294588738,4),x=r(x,e,t,f,a[8],2272392833,11),f=r(f,x,e,t,a[11],1839030562,16),t=r(t,f,x,e,a[14],4259657740,23),e=r(e,t,f,x,a[1],2763975236,4),x=r(x,e,t,f,a[4],1272893353,11),f=r(f,x,e,t,a[7],4139469664,16),t=r(t,f,x,e,a[10],3200236656,23),e=r(e,t,f,x,a[13],681279174,4),x=r(x,e,t,f,a[0],3936430074,11),f=r(f,x,e,t,a[3],3572445317,16),t=r(t,f,x,e,a[6],76029189,23),e=r(e,t,f,x,a[9],3654602809,4),x=r(x,e,t,f,a[12],3873151461,11),f=r(f,x,e,t,a[15],530742520,16),t=r(t,f,x,e,a[2],3299628645,23),e=d(e,t,f,x,a[0],4096336452,6),x=d(x,e,t,f,a[7],1126891415,10),f=d(f,x,e,t,a[14],2878612391,15),t=d(t,f,x,e,a[5],4237533241,21),e=d(e,t,f,x,a[12],1700485571,6),x=d(x,e,t,f,a[3],2399980690,10),f=d(f,x,e,t,a[10],4293915773,15),t=d(t,f,x,e,a[1],2240044497,21),e=d(e,t,f,x,a[8],1873313359,6),x=d(x,e,t,f,a[15],4264355552,10),f=d(f,x,e,t,a[6],2734768916,15),t=d(t,f,x,e,a[13],1309151649,21),e=d(e,t,f,x,a[4],4149444226,6),x=d(x,e,t,f,a[11],3174756917,10),f=d(f,x,e,t,a[2],718787259,15),t=d(t,f,x,e,a[9],3951481745,21),this._a=this._a+e|0,this._b=this._b+t|0,this._c=this._c+f|0,this._d=this._d+x|0};n.prototype._digest=function(){this._block[this._blockOffset++]=128,this._blockOffset>56&&(this._block.fill(0,this._blockOffset,64),this._update(),this._blockOffset=0),this._block.fill(0,this._blockOffset,56),this._block.writeUInt32LE(this._length[0],56),this._block.writeUInt32LE(this._length[1],60),this._update();var a=k.allocUnsafe(16);return a.writeInt32LE(this._a,0),a.writeInt32LE(this._b,4),a.writeInt32LE(this._c,8),a.writeInt32LE(this._d,12),a};function h(a,i){return a<<i|a>>>32-i}function s(a,i,e,t,f,x,b){return h(a+(i&e|~i&t)+f+x|0,b)+i|0}function c(a,i,e,t,f,x,b){return h(a+(i&t|e&~t)+f+x|0,b)+i|0}function r(a,i,e,t,f,x,b){return h(a+(i^e^t)+f+x|0,b)+i|0}function d(a,i,e,t,f,x,b){return h(a+(e^(i|~t))+f+x|0,b)+i|0}var w=n;exports.md5_js=w;
package/dist/index88.js DELETED
@@ -1,37 +0,0 @@
1
- import { i as o } from "./index87.js";
2
- import { h as l } from "./index110.js";
3
- import { s as u } from "./index45.js";
4
- var p = o, n = l, v = u.Buffer, k = new Array(16);
5
- function h() {
6
- n.call(this, 64), this._a = 1732584193, this._b = 4023233417, this._c = 2562383102, this._d = 271733878;
7
- }
8
- p(h, n);
9
- h.prototype._update = function() {
10
- for (var x = k, i = 0; i < 16; ++i) x[i] = this._block.readInt32LE(i * 4);
11
- var f = this._a, t = this._b, e = this._c, a = this._d;
12
- f = s(f, t, e, a, x[0], 3614090360, 7), a = s(a, f, t, e, x[1], 3905402710, 12), e = s(e, a, f, t, x[2], 606105819, 17), t = s(t, e, a, f, x[3], 3250441966, 22), f = s(f, t, e, a, x[4], 4118548399, 7), a = s(a, f, t, e, x[5], 1200080426, 12), e = s(e, a, f, t, x[6], 2821735955, 17), t = s(t, e, a, f, x[7], 4249261313, 22), f = s(f, t, e, a, x[8], 1770035416, 7), a = s(a, f, t, e, x[9], 2336552879, 12), e = s(e, a, f, t, x[10], 4294925233, 17), t = s(t, e, a, f, x[11], 2304563134, 22), f = s(f, t, e, a, x[12], 1804603682, 7), a = s(a, f, t, e, x[13], 4254626195, 12), e = s(e, a, f, t, x[14], 2792965006, 17), t = s(t, e, a, f, x[15], 1236535329, 22), f = c(f, t, e, a, x[1], 4129170786, 5), a = c(a, f, t, e, x[6], 3225465664, 9), e = c(e, a, f, t, x[11], 643717713, 14), t = c(t, e, a, f, x[0], 3921069994, 20), f = c(f, t, e, a, x[5], 3593408605, 5), a = c(a, f, t, e, x[10], 38016083, 9), e = c(e, a, f, t, x[15], 3634488961, 14), t = c(t, e, a, f, x[4], 3889429448, 20), f = c(f, t, e, a, x[9], 568446438, 5), a = c(a, f, t, e, x[14], 3275163606, 9), e = c(e, a, f, t, x[3], 4107603335, 14), t = c(t, e, a, f, x[8], 1163531501, 20), f = c(f, t, e, a, x[13], 2850285829, 5), a = c(a, f, t, e, x[2], 4243563512, 9), e = c(e, a, f, t, x[7], 1735328473, 14), t = c(t, e, a, f, x[12], 2368359562, 20), f = r(f, t, e, a, x[5], 4294588738, 4), a = r(a, f, t, e, x[8], 2272392833, 11), e = r(e, a, f, t, x[11], 1839030562, 16), t = r(t, e, a, f, x[14], 4259657740, 23), f = r(f, t, e, a, x[1], 2763975236, 4), a = r(a, f, t, e, x[4], 1272893353, 11), e = r(e, a, f, t, x[7], 4139469664, 16), t = r(t, e, a, f, x[10], 3200236656, 23), f = r(f, t, e, a, x[13], 681279174, 4), a = r(a, f, t, e, x[0], 3936430074, 11), e = r(e, a, f, t, x[3], 3572445317, 16), t = r(t, e, a, f, x[6], 76029189, 23), f = r(f, t, e, a, x[9], 3654602809, 4), a = r(a, f, t, e, x[12], 3873151461, 11), e = r(e, a, f, t, x[15], 530742520, 16), t = r(t, e, a, f, x[2], 3299628645, 23), f = d(f, t, e, a, x[0], 4096336452, 6), a = d(a, f, t, e, x[7], 1126891415, 10), e = d(e, a, f, t, x[14], 2878612391, 15), t = d(t, e, a, f, x[5], 4237533241, 21), f = d(f, t, e, a, x[12], 1700485571, 6), a = d(a, f, t, e, x[3], 2399980690, 10), e = d(e, a, f, t, x[10], 4293915773, 15), t = d(t, e, a, f, x[1], 2240044497, 21), f = d(f, t, e, a, x[8], 1873313359, 6), a = d(a, f, t, e, x[15], 4264355552, 10), e = d(e, a, f, t, x[6], 2734768916, 15), t = d(t, e, a, f, x[13], 1309151649, 21), f = d(f, t, e, a, x[4], 4149444226, 6), a = d(a, f, t, e, x[11], 3174756917, 10), e = d(e, a, f, t, x[2], 718787259, 15), t = d(t, e, a, f, x[9], 3951481745, 21), this._a = this._a + f | 0, this._b = this._b + t | 0, this._c = this._c + e | 0, this._d = this._d + a | 0;
13
- };
14
- h.prototype._digest = function() {
15
- this._block[this._blockOffset++] = 128, this._blockOffset > 56 && (this._block.fill(0, this._blockOffset, 64), this._update(), this._blockOffset = 0), this._block.fill(0, this._blockOffset, 56), this._block.writeUInt32LE(this._length[0], 56), this._block.writeUInt32LE(this._length[1], 60), this._update();
16
- var x = v.allocUnsafe(16);
17
- return x.writeInt32LE(this._a, 0), x.writeInt32LE(this._b, 4), x.writeInt32LE(this._c, 8), x.writeInt32LE(this._d, 12), x;
18
- };
19
- function _(x, i) {
20
- return x << i | x >>> 32 - i;
21
- }
22
- function s(x, i, f, t, e, a, b) {
23
- return _(x + (i & f | ~i & t) + e + a | 0, b) + i | 0;
24
- }
25
- function c(x, i, f, t, e, a, b) {
26
- return _(x + (i & t | f & ~t) + e + a | 0, b) + i | 0;
27
- }
28
- function r(x, i, f, t, e, a, b) {
29
- return _(x + (i ^ f ^ t) + e + a | 0, b) + i | 0;
30
- }
31
- function d(x, i, f, t, e, a, b) {
32
- return _(x + (f ^ (i | ~t)) + e + a | 0, b) + i | 0;
33
- }
34
- var I = h;
35
- export {
36
- I as m
37
- };
package/dist/index89.cjs DELETED
@@ -1 +0,0 @@
1
- "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});require("./index60.cjs");const R=require("./index87.cjs"),z=require("./index110.cjs"),M=require("./index61.cjs");var L=M.__exports.Buffer,P=R.inherits_browserExports,m=z.hashBase,S=new Array(16),v=[0,1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,7,4,13,1,10,6,15,3,12,0,9,5,2,14,11,8,3,10,14,4,9,15,8,1,2,7,0,6,13,11,5,12,1,9,11,10,0,8,12,4,13,3,7,15,14,5,6,2,4,0,5,9,7,12,2,10,14,1,3,8,11,6,15,13],x=[5,14,7,0,9,2,11,4,13,6,15,8,1,10,3,12,6,11,3,7,0,13,5,10,14,15,8,12,4,9,1,2,15,5,1,3,7,14,6,9,11,8,12,2,10,0,4,13,8,6,4,1,3,11,15,0,5,12,2,13,9,7,10,14,12,15,10,4,1,5,8,7,6,2,13,14,0,3,9,11],p=[11,14,15,12,5,8,7,9,11,13,14,15,6,7,9,8,7,6,8,13,11,9,7,15,7,12,15,9,11,7,13,12,11,13,6,7,14,9,13,15,14,8,13,6,5,12,7,5,11,12,14,15,14,15,9,8,9,14,5,6,8,6,5,12,9,15,5,11,6,8,13,12,5,12,13,14,11,8,5,6],w=[8,9,9,11,13,15,15,5,7,7,8,11,14,14,12,6,9,13,15,7,12,8,9,11,7,7,12,7,6,15,13,11,9,7,15,11,8,6,6,14,12,13,5,14,13,13,7,5,15,5,8,11,14,14,6,14,6,9,12,9,12,5,15,8,8,5,12,9,12,5,14,6,8,13,6,5,15,13,11,11],k=[0,1518500249,1859775393,2400959708,2840853838],E=[1352829926,1548603684,1836072691,2053994217,0];function I(){m.call(this,64),this._a=1732584193,this._b=4023233417,this._c=2562383102,this._d=271733878,this._e=3285377520}P(I,m);I.prototype._update=function(){for(var t=S,s=0;s<16;++s)t[s]=this._block.readInt32LE(s*4);for(var n=this._a|0,e=this._b|0,i=this._c|0,a=this._d|0,h=this._e|0,_=this._a|0,f=this._b|0,c=this._c|0,o=this._d|0,l=this._e|0,r=0;r<80;r+=1){var d,u;r<16?(d=O(n,e,i,a,h,t[v[r]],k[0],p[r]),u=B(_,f,c,o,l,t[x[r]],E[0],w[r])):r<32?(d=g(n,e,i,a,h,t[v[r]],k[1],p[r]),u=q(_,f,c,o,l,t[x[r]],E[1],w[r])):r<48?(d=y(n,e,i,a,h,t[v[r]],k[2],p[r]),u=y(_,f,c,o,l,t[x[r]],E[2],w[r])):r<64?(d=q(n,e,i,a,h,t[v[r]],k[3],p[r]),u=g(_,f,c,o,l,t[x[r]],E[3],w[r])):(d=B(n,e,i,a,h,t[v[r]],k[4],p[r]),u=O(_,f,c,o,l,t[x[r]],E[4],w[r])),n=h,h=a,a=b(i,10),i=e,e=d,_=l,l=o,o=b(c,10),c=f,f=u}var A=this._b+i+o|0;this._b=this._c+a+l|0,this._c=this._d+h+_|0,this._d=this._e+n+f|0,this._e=this._a+e+c|0,this._a=A};I.prototype._digest=function(){this._block[this._blockOffset++]=128,this._blockOffset>56&&(this._block.fill(0,this._blockOffset,64),this._update(),this._blockOffset=0),this._block.fill(0,this._blockOffset,56),this._block.writeUInt32LE(this._length[0],56),this._block.writeUInt32LE(this._length[1],60),this._update();var t=L.alloc?L.alloc(20):new L(20);return t.writeInt32LE(this._a,0),t.writeInt32LE(this._b,4),t.writeInt32LE(this._c,8),t.writeInt32LE(this._d,12),t.writeInt32LE(this._e,16),t};function b(t,s){return t<<s|t>>>32-s}function O(t,s,n,e,i,a,h,_){return b(t+(s^n^e)+a+h|0,_)+i|0}function g(t,s,n,e,i,a,h,_){return b(t+(s&n|~s&e)+a+h|0,_)+i|0}function y(t,s,n,e,i,a,h,_){return b(t+((s|~n)^e)+a+h|0,_)+i|0}function q(t,s,n,e,i,a,h,_){return b(t+(s&e|n&~e)+a+h|0,_)+i|0}function B(t,s,n,e,i,a,h,_){return b(t+(s^(n|~e))+a+h|0,_)+i|0}var U=I;exports.ripemd160=U;