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

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/index89.js DELETED
@@ -1,369 +0,0 @@
1
- import "./index60.js";
2
- import { i as z } from "./index87.js";
3
- import { h as U } from "./index110.js";
4
- import { __exports as D } from "./index61.js";
5
- var m = D.Buffer, H = z, A = U, M = new Array(16), u = [
6
- 0,
7
- 1,
8
- 2,
9
- 3,
10
- 4,
11
- 5,
12
- 6,
13
- 7,
14
- 8,
15
- 9,
16
- 10,
17
- 11,
18
- 12,
19
- 13,
20
- 14,
21
- 15,
22
- 7,
23
- 4,
24
- 13,
25
- 1,
26
- 10,
27
- 6,
28
- 15,
29
- 3,
30
- 12,
31
- 0,
32
- 9,
33
- 5,
34
- 2,
35
- 14,
36
- 11,
37
- 8,
38
- 3,
39
- 10,
40
- 14,
41
- 4,
42
- 9,
43
- 15,
44
- 8,
45
- 1,
46
- 2,
47
- 7,
48
- 0,
49
- 6,
50
- 13,
51
- 11,
52
- 5,
53
- 12,
54
- 1,
55
- 9,
56
- 11,
57
- 10,
58
- 0,
59
- 8,
60
- 12,
61
- 4,
62
- 13,
63
- 3,
64
- 7,
65
- 15,
66
- 14,
67
- 5,
68
- 6,
69
- 2,
70
- 4,
71
- 0,
72
- 5,
73
- 9,
74
- 7,
75
- 12,
76
- 2,
77
- 10,
78
- 14,
79
- 1,
80
- 3,
81
- 8,
82
- 11,
83
- 6,
84
- 15,
85
- 13
86
- ], x = [
87
- 5,
88
- 14,
89
- 7,
90
- 0,
91
- 9,
92
- 2,
93
- 11,
94
- 4,
95
- 13,
96
- 6,
97
- 15,
98
- 8,
99
- 1,
100
- 10,
101
- 3,
102
- 12,
103
- 6,
104
- 11,
105
- 3,
106
- 7,
107
- 0,
108
- 13,
109
- 5,
110
- 10,
111
- 14,
112
- 15,
113
- 8,
114
- 12,
115
- 4,
116
- 9,
117
- 1,
118
- 2,
119
- 15,
120
- 5,
121
- 1,
122
- 3,
123
- 7,
124
- 14,
125
- 6,
126
- 9,
127
- 11,
128
- 8,
129
- 12,
130
- 2,
131
- 10,
132
- 0,
133
- 4,
134
- 13,
135
- 8,
136
- 6,
137
- 4,
138
- 1,
139
- 3,
140
- 11,
141
- 15,
142
- 0,
143
- 5,
144
- 12,
145
- 2,
146
- 13,
147
- 9,
148
- 7,
149
- 10,
150
- 14,
151
- 12,
152
- 15,
153
- 10,
154
- 4,
155
- 1,
156
- 5,
157
- 8,
158
- 7,
159
- 6,
160
- 2,
161
- 13,
162
- 14,
163
- 0,
164
- 3,
165
- 9,
166
- 11
167
- ], p = [
168
- 11,
169
- 14,
170
- 15,
171
- 12,
172
- 5,
173
- 8,
174
- 7,
175
- 9,
176
- 11,
177
- 13,
178
- 14,
179
- 15,
180
- 6,
181
- 7,
182
- 9,
183
- 8,
184
- 7,
185
- 6,
186
- 8,
187
- 13,
188
- 11,
189
- 9,
190
- 7,
191
- 15,
192
- 7,
193
- 12,
194
- 15,
195
- 9,
196
- 11,
197
- 7,
198
- 13,
199
- 12,
200
- 11,
201
- 13,
202
- 6,
203
- 7,
204
- 14,
205
- 9,
206
- 13,
207
- 15,
208
- 14,
209
- 8,
210
- 13,
211
- 6,
212
- 5,
213
- 12,
214
- 7,
215
- 5,
216
- 11,
217
- 12,
218
- 14,
219
- 15,
220
- 14,
221
- 15,
222
- 9,
223
- 8,
224
- 9,
225
- 14,
226
- 5,
227
- 6,
228
- 8,
229
- 6,
230
- 5,
231
- 12,
232
- 9,
233
- 15,
234
- 5,
235
- 11,
236
- 6,
237
- 8,
238
- 13,
239
- 12,
240
- 5,
241
- 12,
242
- 13,
243
- 14,
244
- 11,
245
- 8,
246
- 5,
247
- 6
248
- ], k = [
249
- 8,
250
- 9,
251
- 9,
252
- 11,
253
- 13,
254
- 15,
255
- 15,
256
- 5,
257
- 7,
258
- 7,
259
- 8,
260
- 11,
261
- 14,
262
- 14,
263
- 12,
264
- 6,
265
- 9,
266
- 13,
267
- 15,
268
- 7,
269
- 12,
270
- 8,
271
- 9,
272
- 11,
273
- 7,
274
- 7,
275
- 12,
276
- 7,
277
- 6,
278
- 15,
279
- 13,
280
- 11,
281
- 9,
282
- 7,
283
- 15,
284
- 11,
285
- 8,
286
- 6,
287
- 6,
288
- 14,
289
- 12,
290
- 13,
291
- 5,
292
- 14,
293
- 13,
294
- 13,
295
- 7,
296
- 5,
297
- 15,
298
- 5,
299
- 8,
300
- 11,
301
- 14,
302
- 14,
303
- 6,
304
- 14,
305
- 6,
306
- 9,
307
- 12,
308
- 9,
309
- 12,
310
- 5,
311
- 15,
312
- 8,
313
- 8,
314
- 5,
315
- 12,
316
- 9,
317
- 12,
318
- 5,
319
- 14,
320
- 6,
321
- 8,
322
- 13,
323
- 6,
324
- 5,
325
- 15,
326
- 13,
327
- 11,
328
- 11
329
- ], w = [0, 1518500249, 1859775393, 2400959708, 2840853838], E = [1352829926, 1548603684, 1836072691, 2053994217, 0];
330
- function I() {
331
- A.call(this, 64), this._a = 1732584193, this._b = 4023233417, this._c = 2562383102, this._d = 271733878, this._e = 3285377520;
332
- }
333
- H(I, A);
334
- I.prototype._update = function() {
335
- for (var t = M, e = 0; e < 16; ++e) t[e] = this._block.readInt32LE(e * 4);
336
- for (var f = this._a | 0, s = this._b | 0, a = this._c | 0, h = this._d | 0, i = this._e | 0, _ = this._a | 0, n = this._b | 0, o = this._c | 0, c = this._d | 0, l = this._e | 0, r = 0; r < 80; r += 1) {
337
- var b, d;
338
- r < 16 ? (b = L(f, s, a, h, i, t[u[r]], w[0], p[r]), d = y(_, n, o, c, l, t[x[r]], E[0], k[r])) : r < 32 ? (b = O(f, s, a, h, i, t[u[r]], w[1], p[r]), d = g(_, n, o, c, l, t[x[r]], E[1], k[r])) : r < 48 ? (b = B(f, s, a, h, i, t[u[r]], w[2], p[r]), d = B(_, n, o, c, l, t[x[r]], E[2], k[r])) : r < 64 ? (b = g(f, s, a, h, i, t[u[r]], w[3], p[r]), d = O(_, n, o, c, l, t[x[r]], E[3], k[r])) : (b = y(f, s, a, h, i, t[u[r]], w[4], p[r]), d = L(_, n, o, c, l, t[x[r]], E[4], k[r])), f = i, i = h, h = v(a, 10), a = s, s = b, _ = l, l = c, c = v(o, 10), o = n, n = d;
339
- }
340
- var R = this._b + a + c | 0;
341
- this._b = this._c + h + l | 0, this._c = this._d + i + _ | 0, this._d = this._e + f + n | 0, this._e = this._a + s + o | 0, this._a = R;
342
- };
343
- I.prototype._digest = function() {
344
- 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();
345
- var t = m.alloc ? m.alloc(20) : new m(20);
346
- 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;
347
- };
348
- function v(t, e) {
349
- return t << e | t >>> 32 - e;
350
- }
351
- function L(t, e, f, s, a, h, i, _) {
352
- return v(t + (e ^ f ^ s) + h + i | 0, _) + a | 0;
353
- }
354
- function O(t, e, f, s, a, h, i, _) {
355
- return v(t + (e & f | ~e & s) + h + i | 0, _) + a | 0;
356
- }
357
- function B(t, e, f, s, a, h, i, _) {
358
- return v(t + ((e | ~f) ^ s) + h + i | 0, _) + a | 0;
359
- }
360
- function g(t, e, f, s, a, h, i, _) {
361
- return v(t + (e & s | f & ~s) + h + i | 0, _) + a | 0;
362
- }
363
- function y(t, e, f, s, a, h, i, _) {
364
- return v(t + (e ^ (f | ~s)) + h + i | 0, _) + a | 0;
365
- }
366
- var F = I;
367
- export {
368
- F as r
369
- };
package/dist/index9.cjs DELETED
@@ -1 +0,0 @@
1
- "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const r=require("@catalogfi/utils"),u=require("@gardenfi/utils"),i=require("./index10.cjs");class a{constructor(t){this.quoteUrl=new u.Url("/quote",t)}async getQuote(t,e,s=!1){try{const o=this.quoteUrl.addSearchParams({order_pair:t,amount:e.toString(),exact_out:s.toString()}),n=await r.Fetcher.get(o);return n.error?r.Err(n.error):n.result?r.Ok(n.result):r.Err("GetQuote: Unexpected error, result is undefined")}catch(o){return r.Err("GetQuote:",String(o))}}async getAttestedQuote(t){try{const e=await r.Fetcher.post(this.quoteUrl.endpoint("/attested").toString(),{body:JSON.stringify(t),headers:{"Content-Type":"application/json"}});return e.error?r.Err(e.error):e.result?r.Ok(e.result):r.Err("GetAttestedQuote: Unexpected error, result is undefined")}catch(e){return console.log("error :",e),r.Err("GetAttestedQuote:",String(e))}}async getStrategies(){try{const t=await r.Fetcher.get(this.quoteUrl.endpoint("/strategies"));if(t.error)return r.Err(t.error);if(!t.result)return r.Err("GetStrategies: Unexpected error, result is undefined");const e={};for(const s of Object.values(t.result)){const o=i.constructOrderPair(s.source_chain,s.source_asset.asset,s.dest_chain,s.dest_asset.asset);e[o]={id:s.id,minAmount:s.min_amount,maxAmount:s.max_amount}}return r.Ok(e)}catch(t){return r.Err("GetStrategies:",String(t))}}}exports.Quote=a;
package/dist/index9.js DELETED
@@ -1,63 +0,0 @@
1
- import { Fetcher as u, Err as o, Ok as i } from "@catalogfi/utils";
2
- import { Url as a } from "@gardenfi/utils";
3
- import { constructOrderPair as c } from "./index10.js";
4
- class m {
5
- constructor(t) {
6
- this.quoteUrl = new a("/quote", t);
7
- }
8
- async getQuote(t, r, e = !1) {
9
- try {
10
- const s = this.quoteUrl.addSearchParams({
11
- order_pair: t,
12
- amount: r.toString(),
13
- exact_out: e.toString()
14
- }), n = await u.get(s);
15
- return n.error ? o(n.error) : n.result ? i(n.result) : o("GetQuote: Unexpected error, result is undefined");
16
- } catch (s) {
17
- return o("GetQuote:", String(s));
18
- }
19
- }
20
- async getAttestedQuote(t) {
21
- try {
22
- const r = await u.post(this.quoteUrl.endpoint("/attested").toString(), {
23
- body: JSON.stringify(t),
24
- headers: {
25
- "Content-Type": "application/json"
26
- }
27
- });
28
- return r.error ? o(r.error) : r.result ? i(r.result) : o("GetAttestedQuote: Unexpected error, result is undefined");
29
- } catch (r) {
30
- return console.log("error :", r), o("GetAttestedQuote:", String(r));
31
- }
32
- }
33
- async getStrategies() {
34
- try {
35
- const t = await u.get(
36
- this.quoteUrl.endpoint("/strategies")
37
- );
38
- if (t.error) return o(t.error);
39
- if (!t.result)
40
- return o("GetStrategies: Unexpected error, result is undefined");
41
- const r = {};
42
- for (const e of Object.values(t.result)) {
43
- const s = c(
44
- e.source_chain,
45
- e.source_asset.asset,
46
- e.dest_chain,
47
- e.dest_asset.asset
48
- );
49
- r[s] = {
50
- id: e.id,
51
- minAmount: e.min_amount,
52
- maxAmount: e.max_amount
53
- };
54
- }
55
- return i(r);
56
- } catch (t) {
57
- return o("GetStrategies:", String(t));
58
- }
59
- }
60
- }
61
- export {
62
- m as Quote
63
- };
package/dist/index90.cjs DELETED
@@ -1 +0,0 @@
1
- "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const a=require("./index111.cjs"),t=require("./index112.cjs"),o=require("./index113.cjs"),h=require("./index114.cjs"),u=require("./index115.cjs"),n=require("./index116.cjs"),c=require("./index117.cjs");var s=a.__module.exports=function(e){e=e.toLowerCase();var r=s[e];if(!r)throw new Error(e+" is not supported (we accept pull requests)");return new r};s.sha=t.sha;s.sha1=o.sha1;s.sha224=h.sha224;s.sha256=u.sha256;s.sha384=n.sha384;s.sha512=c.sha512;var i=a.__module.exports;exports.sha_jsExports=i;
package/dist/index90.js DELETED
@@ -1,23 +0,0 @@
1
- import { __module as a } from "./index111.js";
2
- import { s as t } from "./index112.js";
3
- import { s as p } from "./index113.js";
4
- import { s as e } from "./index114.js";
5
- import { s as h } from "./index115.js";
6
- import { s as m } from "./index116.js";
7
- import { s as f } from "./index117.js";
8
- var s = a.exports = function(r) {
9
- r = r.toLowerCase();
10
- var o = s[r];
11
- if (!o) throw new Error(r + " is not supported (we accept pull requests)");
12
- return new o();
13
- };
14
- s.sha = t;
15
- s.sha1 = p;
16
- s.sha224 = e;
17
- s.sha256 = h;
18
- s.sha384 = m;
19
- s.sha512 = f;
20
- var d = a.exports;
21
- export {
22
- d as s
23
- };
package/dist/index91.cjs DELETED
@@ -1 +0,0 @@
1
- "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const a=require("./index45.cjs"),f=require("./index118.cjs");require("./index119.cjs");const u=require("./index87.cjs"),_=require("./index120.cjs");var n=a.safeBufferExports.Buffer,s=f.Transform,p=_.__exports.StringDecoder,c=u.inherits_browserExports;function e(t){s.call(this),this.hashMode=typeof t=="string",this.hashMode?this[t]=this._finalOrDigest:this.final=this._finalOrDigest,this._final&&(this.__final=this._final,this._final=null),this._decoder=null,this._encoding=null}c(e,s);e.prototype.update=function(t,r,o){typeof t=="string"&&(t=n.from(t,r));var i=this._update(t);return this.hashMode?this:(o&&(i=this._toString(i,o)),i)};e.prototype.setAutoPadding=function(){};e.prototype.getAuthTag=function(){throw new Error("trying to get auth tag in unsupported state")};e.prototype.setAuthTag=function(){throw new Error("trying to set auth tag in unsupported state")};e.prototype.setAAD=function(){throw new Error("trying to set aad in unsupported state")};e.prototype._transform=function(t,r,o){var i;try{this.hashMode?this._update(t):this.push(this._update(t))}catch(h){i=h}finally{o(i)}};e.prototype._flush=function(t){var r;try{this.push(this.__final())}catch(o){r=o}t(r)};e.prototype._finalOrDigest=function(t){var r=this.__final()||n.alloc(0);return t&&(r=this._toString(r,t,!0)),r};e.prototype._toString=function(t,r,o){if(this._decoder||(this._decoder=new p(r),this._encoding=r),this._encoding!==r)throw new Error("can't switch encodings");var i=this._decoder.write(t);return o&&(i+=this._decoder.end()),i};var d=e;exports.cipherBase=d;
package/dist/index91.js DELETED
@@ -1,58 +0,0 @@
1
- import { s as a } from "./index45.js";
2
- import f from "./index118.js";
3
- import "./index119.js";
4
- import { i as p } from "./index87.js";
5
- import { __exports as u } from "./index120.js";
6
- var s = a.Buffer, n = f.Transform, _ = u.StringDecoder, c = p;
7
- function i(t) {
8
- n.call(this), this.hashMode = typeof t == "string", this.hashMode ? this[t] = this._finalOrDigest : this.final = this._finalOrDigest, this._final && (this.__final = this._final, this._final = null), this._decoder = null, this._encoding = null;
9
- }
10
- c(i, n);
11
- i.prototype.update = function(t, r, o) {
12
- typeof t == "string" && (t = s.from(t, r));
13
- var e = this._update(t);
14
- return this.hashMode ? this : (o && (e = this._toString(e, o)), e);
15
- };
16
- i.prototype.setAutoPadding = function() {
17
- };
18
- i.prototype.getAuthTag = function() {
19
- throw new Error("trying to get auth tag in unsupported state");
20
- };
21
- i.prototype.setAuthTag = function() {
22
- throw new Error("trying to set auth tag in unsupported state");
23
- };
24
- i.prototype.setAAD = function() {
25
- throw new Error("trying to set aad in unsupported state");
26
- };
27
- i.prototype._transform = function(t, r, o) {
28
- var e;
29
- try {
30
- this.hashMode ? this._update(t) : this.push(this._update(t));
31
- } catch (h) {
32
- e = h;
33
- } finally {
34
- o(e);
35
- }
36
- };
37
- i.prototype._flush = function(t) {
38
- var r;
39
- try {
40
- this.push(this.__final());
41
- } catch (o) {
42
- r = o;
43
- }
44
- t(r);
45
- };
46
- i.prototype._finalOrDigest = function(t) {
47
- var r = this.__final() || s.alloc(0);
48
- return t && (r = this._toString(r, t, !0)), r;
49
- };
50
- i.prototype._toString = function(t, r, o) {
51
- if (this._decoder || (this._decoder = new _(r), this._encoding = r), this._encoding !== r) throw new Error("can't switch encodings");
52
- var e = this._decoder.write(t);
53
- return o && (e += this._decoder.end()), e;
54
- };
55
- var w = i;
56
- export {
57
- w as c
58
- };
package/dist/index92.cjs DELETED
@@ -1 +0,0 @@
1
- "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("./index121.cjs");var r=e.src,s="123456789ABCDEFGHJKLMNPQRSTUVWXYZabcdefghijkmnopqrstuvwxyz",t=r(s);exports.bs58=t;
package/dist/index92.js DELETED
@@ -1,5 +0,0 @@
1
- import { s as r } from "./index121.js";
2
- var a = r, s = "123456789ABCDEFGHJKLMNPQRSTUVWXYZabcdefghijkmnopqrstuvwxyz", o = a(s);
3
- export {
4
- o as b
5
- };
package/dist/index93.cjs DELETED
@@ -1 +0,0 @@
1
- "use strict";const f=require("./index95.cjs");f.__exports.byteLength=l;f.__exports.toByteArray=C;f.__exports.fromByteArray=g;var x=[],c=[],u=typeof Uint8Array<"u"?Uint8Array:Array,s="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/";for(var F=0,A=s.length;F<A;++F)x[F]=s[F],c[s.charCodeAt(F)]=F;c[45]=62;c[95]=63;function p(r){var e=r.length;if(e%4>0)throw new Error("Invalid string. Length must be a multiple of 4");var t=r.indexOf("=");t===-1&&(t=e);var o=t===e?0:4-t%4;return[t,o]}function l(r){var e=p(r),t=e[0],o=e[1];return(t+o)*3/4-o}function y(r,e,t){return(e+t)*3/4-t}function C(r){var e,t=p(r),o=t[0],n=t[1],a=new u(y(r,o,n)),v=0,d=n>0?o-4:o,h;for(h=0;h<d;h+=4)e=c[r.charCodeAt(h)]<<18|c[r.charCodeAt(h+1)]<<12|c[r.charCodeAt(h+2)]<<6|c[r.charCodeAt(h+3)],a[v++]=e>>16&255,a[v++]=e>>8&255,a[v++]=e&255;return n===2&&(e=c[r.charCodeAt(h)]<<2|c[r.charCodeAt(h+1)]>>4,a[v++]=e&255),n===1&&(e=c[r.charCodeAt(h)]<<10|c[r.charCodeAt(h+1)]<<4|c[r.charCodeAt(h+2)]>>2,a[v++]=e>>8&255,a[v++]=e&255),a}function L(r){return x[r>>18&63]+x[r>>12&63]+x[r>>6&63]+x[r&63]}function i(r,e,t){for(var o,n=[],a=e;a<t;a+=3)o=(r[a]<<16&16711680)+(r[a+1]<<8&65280)+(r[a+2]&255),n.push(L(o));return n.join("")}function g(r){for(var e,t=r.length,o=t%3,n=[],a=16383,v=0,d=t-o;v<d;v+=a)n.push(i(r,v,v+a>d?d:v+a));return o===1?(e=r[t-1],n.push(x[e>>2]+x[e<<4&63]+"==")):o===2&&(e=(r[t-2]<<8)+r[t-1],n.push(x[e>>10]+x[e>>4&63]+x[e<<2&63]+"=")),n.join("")}module.exports=f.__exports;
package/dist/index93.js DELETED
@@ -1,51 +0,0 @@
1
- import { __exports as l } from "./index95.js";
2
- l.byteLength = p;
3
- l.toByteArray = C;
4
- l.fromByteArray = i;
5
- var F = [], f = [], u = typeof Uint8Array < "u" ? Uint8Array : Array, x = "ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/";
6
- for (var c = 0, A = x.length; c < A; ++c)
7
- F[c] = x[c], f[x.charCodeAt(c)] = c;
8
- f[45] = 62;
9
- f[95] = 63;
10
- function s(r) {
11
- var e = r.length;
12
- if (e % 4 > 0)
13
- throw new Error("Invalid string. Length must be a multiple of 4");
14
- var a = r.indexOf("=");
15
- a === -1 && (a = e);
16
- var o = a === e ? 0 : 4 - a % 4;
17
- return [a, o];
18
- }
19
- function p(r) {
20
- var e = s(r), a = e[0], o = e[1];
21
- return (a + o) * 3 / 4 - o;
22
- }
23
- function y(r, e, a) {
24
- return (e + a) * 3 / 4 - a;
25
- }
26
- function C(r) {
27
- var e, a = s(r), o = a[0], n = a[1], t = new u(y(r, o, n)), v = 0, d = n > 0 ? o - 4 : o, h;
28
- for (h = 0; h < d; h += 4)
29
- e = f[r.charCodeAt(h)] << 18 | f[r.charCodeAt(h + 1)] << 12 | f[r.charCodeAt(h + 2)] << 6 | f[r.charCodeAt(h + 3)], t[v++] = e >> 16 & 255, t[v++] = e >> 8 & 255, t[v++] = e & 255;
30
- return n === 2 && (e = f[r.charCodeAt(h)] << 2 | f[r.charCodeAt(h + 1)] >> 4, t[v++] = e & 255), n === 1 && (e = f[r.charCodeAt(h)] << 10 | f[r.charCodeAt(h + 1)] << 4 | f[r.charCodeAt(h + 2)] >> 2, t[v++] = e >> 8 & 255, t[v++] = e & 255), t;
31
- }
32
- function L(r) {
33
- return F[r >> 18 & 63] + F[r >> 12 & 63] + F[r >> 6 & 63] + F[r & 63];
34
- }
35
- function g(r, e, a) {
36
- for (var o, n = [], t = e; t < a; t += 3)
37
- o = (r[t] << 16 & 16711680) + (r[t + 1] << 8 & 65280) + (r[t + 2] & 255), n.push(L(o));
38
- return n.join("");
39
- }
40
- function i(r) {
41
- for (var e, a = r.length, o = a % 3, n = [], t = 16383, v = 0, d = a - o; v < d; v += t)
42
- n.push(g(r, v, v + t > d ? d : v + t));
43
- return o === 1 ? (e = r[a - 1], n.push(
44
- F[e >> 2] + F[e << 4 & 63] + "=="
45
- )) : o === 2 && (e = (r[a - 2] << 8) + r[a - 1], n.push(
46
- F[e >> 10] + F[e >> 4 & 63] + F[e << 2 & 63] + "="
47
- )), n.join("");
48
- }
49
- export {
50
- l as default
51
- };
package/dist/index94.cjs DELETED
@@ -1 +0,0 @@
1
- "use strict";const d=require("./index96.cjs");/*! ieee754. BSD-3-Clause License. Feross Aboukhadijeh <https://feross.org/opensource> */d.__exports.read=function(w,a,_,x,M){var t,r,h=M*8-x-1,s=(1<<h)-1,N=s>>1,i=-7,o=_?M-1:0,c=_?-1:1,p=w[a+o];for(o+=c,t=p&(1<<-i)-1,p>>=-i,i+=h;i>0;t=t*256+w[a+o],o+=c,i-=8);for(r=t&(1<<-i)-1,t>>=-i,i+=x;i>0;r=r*256+w[a+o],o+=c,i-=8);if(t===0)t=1-N;else{if(t===s)return r?NaN:(p?-1:1)*(1/0);r=r+Math.pow(2,x),t=t-N}return(p?-1:1)*r*Math.pow(2,t-x)};d.__exports.write=function(w,a,_,x,M,t){var r,h,s,N=t*8-M-1,i=(1<<N)-1,o=i>>1,c=M===23?Math.pow(2,-24)-Math.pow(2,-77):0,p=x?0:t-1,f=x?1:-1,n=a<0||a===0&&1/a<0?1:0;for(a=Math.abs(a),isNaN(a)||a===1/0?(h=isNaN(a)?1:0,r=i):(r=Math.floor(Math.log(a)/Math.LN2),a*(s=Math.pow(2,-r))<1&&(r--,s*=2),r+o>=1?a+=c/s:a+=c*Math.pow(2,1-o),a*s>=2&&(r++,s/=2),r+o>=i?(h=0,r=i):r+o>=1?(h=(a*s-1)*Math.pow(2,M),r=r+o):(h=a*Math.pow(2,o-1)*Math.pow(2,M),r=0));M>=8;w[_+p]=h&255,p+=f,h/=256,M-=8);for(r=r<<M|h,N+=M;N>0;w[_+p]=r&255,p+=f,r/=256,N-=8);w[_+p-f]|=n*128};module.exports=d.__exports;
package/dist/index94.js DELETED
@@ -1,28 +0,0 @@
1
- import { __exports as v } from "./index96.js";
2
- /*! ieee754. BSD-3-Clause License. Feross Aboukhadijeh <https://feross.org/opensource> */
3
- v.read = function(s, a, x, f, M) {
4
- var t, r, h = M * 8 - f - 1, w = (1 << h) - 1, N = w >> 1, i = -7, o = x ? M - 1 : 0, d = x ? -1 : 1, p = s[a + o];
5
- for (o += d, t = p & (1 << -i) - 1, p >>= -i, i += h; i > 0; t = t * 256 + s[a + o], o += d, i -= 8)
6
- ;
7
- for (r = t & (1 << -i) - 1, t >>= -i, i += f; i > 0; r = r * 256 + s[a + o], o += d, i -= 8)
8
- ;
9
- if (t === 0)
10
- t = 1 - N;
11
- else {
12
- if (t === w)
13
- return r ? NaN : (p ? -1 : 1) * (1 / 0);
14
- r = r + Math.pow(2, f), t = t - N;
15
- }
16
- return (p ? -1 : 1) * r * Math.pow(2, t - f);
17
- };
18
- v.write = function(s, a, x, f, M, t) {
19
- var r, h, w, N = t * 8 - M - 1, i = (1 << N) - 1, o = i >> 1, d = M === 23 ? Math.pow(2, -24) - Math.pow(2, -77) : 0, p = f ? 0 : t - 1, c = f ? 1 : -1, I = a < 0 || a === 0 && 1 / a < 0 ? 1 : 0;
20
- for (a = Math.abs(a), isNaN(a) || a === 1 / 0 ? (h = isNaN(a) ? 1 : 0, r = i) : (r = Math.floor(Math.log(a) / Math.LN2), a * (w = Math.pow(2, -r)) < 1 && (r--, w *= 2), r + o >= 1 ? a += d / w : a += d * Math.pow(2, 1 - o), a * w >= 2 && (r++, w /= 2), r + o >= i ? (h = 0, r = i) : r + o >= 1 ? (h = (a * w - 1) * Math.pow(2, M), r = r + o) : (h = a * Math.pow(2, o - 1) * Math.pow(2, M), r = 0)); M >= 8; s[x + p] = h & 255, p += c, h /= 256, M -= 8)
21
- ;
22
- for (r = r << M | h, N += M; N > 0; s[x + p] = r & 255, p += c, r /= 256, N -= 8)
23
- ;
24
- s[x + p - c] |= I * 128;
25
- };
26
- export {
27
- v as default
28
- };
package/dist/index95.cjs DELETED
@@ -1 +0,0 @@
1
- "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});var e={};exports.__exports=e;
package/dist/index95.js DELETED
@@ -1,4 +0,0 @@
1
- var s = {};
2
- export {
3
- s as __exports
4
- };
package/dist/index96.cjs DELETED
@@ -1 +0,0 @@
1
- "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});var e={};exports.__exports=e;
package/dist/index96.js DELETED
@@ -1,4 +0,0 @@
1
- var e = {};
2
- export {
3
- e as __exports
4
- };
package/dist/index97.cjs DELETED
@@ -1 +0,0 @@
1
- "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const t=require("./index66.cjs");class i extends t.BaseError{constructor({offset:r,position:s,size:e}){super(`Slice ${s==="start"?"starting":"ending"} at offset "${r}" is out-of-bounds (size: ${e}).`,{name:"SliceOffsetOutOfBoundsError"})}}class d extends t.BaseError{constructor({size:r,targetSize:s,type:e}){super(`${e.charAt(0).toUpperCase()}${e.slice(1).toLowerCase()} size (${r}) exceeds padding size (${s}).`,{name:"SizeExceedsPaddingSizeError"})}}exports.SizeExceedsPaddingSizeError=d;exports.SliceOffsetOutOfBoundsError=i;
package/dist/index97.js DELETED
@@ -1,15 +0,0 @@
1
- import { BaseError as o } from "./index66.js";
2
- class d extends o {
3
- constructor({ offset: r, position: s, size: e }) {
4
- super(`Slice ${s === "start" ? "starting" : "ending"} at offset "${r}" is out-of-bounds (size: ${e}).`, { name: "SliceOffsetOutOfBoundsError" });
5
- }
6
- }
7
- class n extends o {
8
- constructor({ size: r, targetSize: s, type: e }) {
9
- super(`${e.charAt(0).toUpperCase()}${e.slice(1).toLowerCase()} size (${r}) exceeds padding size (${s}).`, { name: "SizeExceedsPaddingSizeError" });
10
- }
11
- }
12
- export {
13
- n as SizeExceedsPaddingSizeError,
14
- d as SliceOffsetOutOfBoundsError
15
- };
package/dist/index98.cjs DELETED
@@ -1 +0,0 @@
1
- "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("./index99.cjs"),s=require("./index67.cjs"),r=require("./index65.cjs");function o(t,i){return e.sha256(s.isHex(t,{strict:!1})?r.toBytes(t):t)}exports.sha256=o;
package/dist/index98.js DELETED
@@ -1,9 +0,0 @@
1
- import { sha256 as o } from "./index99.js";
2
- import { isHex as s } from "./index67.js";
3
- import { toBytes as r } from "./index65.js";
4
- function p(t, i) {
5
- return o(s(t, { strict: !1 }) ? r(t) : t);
6
- }
7
- export {
8
- p as sha256
9
- };
package/dist/index99.cjs DELETED
@@ -1 +0,0 @@
1
- "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const H=require("./index122.cjs"),s=require("./index123.cjs"),S=new Uint32Array([1116352408,1899447441,3049323471,3921009573,961987163,1508970993,2453635748,2870763221,3624381080,310598401,607225278,1426881987,1925078388,2162078206,2614888103,3248222580,3835390401,4022224774,264347078,604807628,770255983,1249150122,1555081692,1996064986,2554220882,2821834349,2952996808,3210313671,3336571891,3584528711,113926993,338241895,666307205,773529912,1294757372,1396182291,1695183700,1986661051,2177026350,2456956037,2730485921,2820302411,3259730800,3345764771,3516065817,3600352804,4094571909,275423344,430227734,506948616,659060556,883997877,958139571,1322822218,1537002063,1747873779,1955562222,2024104815,2227730452,2361852424,2428436474,2756734187,3204031479,3329325298]),b=new Uint32Array([1779033703,3144134277,1013904242,2773480762,1359893119,2600822924,528734635,1541459225]),f=new Uint32Array(64);class g extends H.HashMD{constructor(){super(64,32,8,!1),this.A=b[0]|0,this.B=b[1]|0,this.C=b[2]|0,this.D=b[3]|0,this.E=b[4]|0,this.F=b[5]|0,this.G=b[6]|0,this.H=b[7]|0}get(){const{A:d,B:o,C:x,D:e,E:a,F:i,G:c,H:r}=this;return[d,o,x,e,a,i,c,r]}set(d,o,x,e,a,i,c,r){this.A=d|0,this.B=o|0,this.C=x|0,this.D=e|0,this.E=a|0,this.F=i|0,this.G=c|0,this.H=r|0}process(d,o){for(let t=0;t<16;t++,o+=4)f[t]=d.getUint32(o,!1);for(let t=16;t<64;t++){const A=f[t-15],n=f[t-2],C=s.rotr(A,7)^s.rotr(A,18)^A>>>3,u=s.rotr(n,17)^s.rotr(n,19)^n>>>10;f[t]=u+f[t-7]+C+f[t-16]|0}let{A:x,B:e,C:a,D:i,E:c,F:r,G:h,H:l}=this;for(let t=0;t<64;t++){const A=s.rotr(c,6)^s.rotr(c,11)^s.rotr(c,25),n=l+A+H.Chi(c,r,h)+S[t]+f[t]|0,u=(s.rotr(x,2)^s.rotr(x,13)^s.rotr(x,22))+H.Maj(x,e,a)|0;l=h,h=r,r=c,c=i+n|0,i=a,a=e,e=x,x=n+u|0}x=x+this.A|0,e=e+this.B|0,a=a+this.C|0,i=i+this.D|0,c=c+this.E|0,r=r+this.F|0,h=h+this.G|0,l=l+this.H|0,this.set(x,e,a,i,c,r,h,l)}roundClean(){f.fill(0)}destroy(){this.set(0,0,0,0,0,0,0,0),this.buffer.fill(0)}}const y=s.wrapConstructor(()=>new g);exports.SHA256=g;exports.sha256=y;