tenjin-cli 0.1.0-alpha.0 → 0.1.0-alpha.1

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 (51) hide show
  1. package/README.md +39 -7
  2. package/dist/{ccip-FXWZDDF5.js → ccip-UCLT5VOW.js} +4 -4
  3. package/dist/{chunk-F5DZJLU3.js → chunk-BRJHUQSY.js} +770 -59
  4. package/dist/chunk-BRJHUQSY.js.map +1 -0
  5. package/dist/{chunk-CPUZRZ2A.js → chunk-CUWUHTIL.js} +42 -1
  6. package/dist/{chunk-CPUZRZ2A.js.map → chunk-CUWUHTIL.js.map} +1 -1
  7. package/dist/{chunk-376LHMK2.js → chunk-DXPYFVKG.js} +32 -6
  8. package/dist/chunk-DXPYFVKG.js.map +1 -0
  9. package/dist/chunk-EXBMF5X7.js +1198 -0
  10. package/dist/chunk-EXBMF5X7.js.map +1 -0
  11. package/dist/{chunk-LTTRND4A.js → chunk-EZROUI5U.js} +2 -2
  12. package/dist/{chunk-PAAL45FJ.js → chunk-IPOWB3G3.js} +123 -133
  13. package/dist/chunk-IPOWB3G3.js.map +1 -0
  14. package/dist/{chunk-WOHCAMDQ.js → chunk-LPRVHM7P.js} +14 -697
  15. package/dist/chunk-LPRVHM7P.js.map +1 -0
  16. package/dist/{chunk-TX5T3LKJ.js → chunk-Q53IYV2G.js} +3 -2
  17. package/dist/{chunk-SXQQ2ZSR.js → chunk-T4LKNY7T.js} +24 -11
  18. package/dist/chunk-T4LKNY7T.js.map +1 -0
  19. package/dist/chunk-YBMMV4Y4.js +51 -0
  20. package/dist/chunk-YBMMV4Y4.js.map +1 -0
  21. package/dist/{chunk-FIYZLITH.js → chunk-YG2DO46P.js} +6 -2
  22. package/dist/{chunk-FIYZLITH.js.map → chunk-YG2DO46P.js.map} +1 -1
  23. package/dist/{cli-LMHGCZ5S.js → cli-WA65NP4Y.js} +13 -17
  24. package/dist/{cli-LMHGCZ5S.js.map → cli-WA65NP4Y.js.map} +1 -1
  25. package/dist/{config-XVXZ3V2Q.js → config-CEFTL5ZL.js} +9 -51
  26. package/dist/config-CEFTL5ZL.js.map +1 -0
  27. package/dist/{doctor-MVLZRVPU.js → doctor-3QBYN46N.js} +7 -7
  28. package/dist/index.js +1 -1
  29. package/dist/{secp256k1-35YNNB6F.js → secp256k1-BEZS642W.js} +3 -3
  30. package/dist/{usdc-OQUOFF6R.js → usdc-44R6XZF2.js} +7 -7
  31. package/dist/{wallet-QUWK2PA4.js → wallet-ELBTBMXO.js} +8 -10
  32. package/dist/wallet-XD576HF3.js +173 -0
  33. package/dist/wallet-XD576HF3.js.map +1 -0
  34. package/package.json +3 -1
  35. package/dist/chunk-376LHMK2.js.map +0 -1
  36. package/dist/chunk-F5DZJLU3.js.map +0 -1
  37. package/dist/chunk-PAAL45FJ.js.map +0 -1
  38. package/dist/chunk-QHIEYBLV.js +0 -320
  39. package/dist/chunk-QHIEYBLV.js.map +0 -1
  40. package/dist/chunk-SXQQ2ZSR.js.map +0 -1
  41. package/dist/chunk-WOHCAMDQ.js.map +0 -1
  42. package/dist/config-XVXZ3V2Q.js.map +0 -1
  43. package/dist/wallet-NRKWLKHX.js +0 -153
  44. package/dist/wallet-NRKWLKHX.js.map +0 -1
  45. /package/dist/{ccip-FXWZDDF5.js.map → ccip-UCLT5VOW.js.map} +0 -0
  46. /package/dist/{chunk-LTTRND4A.js.map → chunk-EZROUI5U.js.map} +0 -0
  47. /package/dist/{chunk-TX5T3LKJ.js.map → chunk-Q53IYV2G.js.map} +0 -0
  48. /package/dist/{doctor-MVLZRVPU.js.map → doctor-3QBYN46N.js.map} +0 -0
  49. /package/dist/{secp256k1-35YNNB6F.js.map → secp256k1-BEZS642W.js.map} +0 -0
  50. /package/dist/{usdc-OQUOFF6R.js.map → usdc-44R6XZF2.js.map} +0 -0
  51. /package/dist/{wallet-QUWK2PA4.js.map → wallet-ELBTBMXO.js.map} +0 -0
@@ -41,6 +41,7 @@ import {
41
41
  formatAbiItem,
42
42
  formatEther,
43
43
  formatGwei,
44
+ fromNumber,
44
45
  getArrayComponents,
45
46
  hexToBigInt,
46
47
  hexToBytes,
@@ -58,7 +59,7 @@ import {
58
59
  stringify,
59
60
  toBytes,
60
61
  trim
61
- } from "./chunk-F5DZJLU3.js";
62
+ } from "./chunk-BRJHUQSY.js";
62
63
 
63
64
  // node_modules/.pnpm/abitype@1.2.3_typescript@6.0.3_zod@4.4.3/node_modules/abitype/dist/esm/version.js
64
65
  var version = "1.2.3";
@@ -855,663 +856,6 @@ function parseAbiParameters(params) {
855
856
  return abiParameters;
856
857
  }
857
858
 
858
- // node_modules/.pnpm/ox@0.14.30_typescript@6.0.3_zod@4.4.3/node_modules/ox/_esm/core/version.js
859
- var version2 = "0.1.1";
860
-
861
- // node_modules/.pnpm/ox@0.14.30_typescript@6.0.3_zod@4.4.3/node_modules/ox/_esm/core/internal/errors.js
862
- function getVersion() {
863
- return version2;
864
- }
865
-
866
- // node_modules/.pnpm/ox@0.14.30_typescript@6.0.3_zod@4.4.3/node_modules/ox/_esm/core/Errors.js
867
- var BaseError3 = class _BaseError extends Error {
868
- static setStaticOptions(options) {
869
- _BaseError.prototype.docsOrigin = options.docsOrigin;
870
- _BaseError.prototype.showVersion = options.showVersion;
871
- _BaseError.prototype.version = options.version;
872
- }
873
- constructor(shortMessage, options = {}) {
874
- const details = (() => {
875
- if (options.cause instanceof _BaseError) {
876
- if (options.cause.details)
877
- return options.cause.details;
878
- if (options.cause.shortMessage)
879
- return options.cause.shortMessage;
880
- }
881
- if (options.cause && "details" in options.cause && typeof options.cause.details === "string")
882
- return options.cause.details;
883
- if (options.cause?.message)
884
- return options.cause.message;
885
- return options.details;
886
- })();
887
- const docsPath6 = (() => {
888
- if (options.cause instanceof _BaseError)
889
- return options.cause.docsPath || options.docsPath;
890
- return options.docsPath;
891
- })();
892
- const docsBaseUrl = options.docsOrigin ?? _BaseError.prototype.docsOrigin;
893
- const docs = `${docsBaseUrl}${docsPath6 ?? ""}`;
894
- const showVersion = Boolean(options.version ?? _BaseError.prototype.showVersion);
895
- const version3 = options.version ?? _BaseError.prototype.version;
896
- const message = [
897
- shortMessage || "An error occurred.",
898
- ...options.metaMessages ? ["", ...options.metaMessages] : [],
899
- ...details || docsPath6 || showVersion ? [
900
- "",
901
- details ? `Details: ${details}` : void 0,
902
- docsPath6 ? `See: ${docs}` : void 0,
903
- showVersion ? `Version: ${version3}` : void 0
904
- ] : []
905
- ].filter((x) => typeof x === "string").join("\n");
906
- super(message, options.cause ? { cause: options.cause } : void 0);
907
- Object.defineProperty(this, "details", {
908
- enumerable: true,
909
- configurable: true,
910
- writable: true,
911
- value: void 0
912
- });
913
- Object.defineProperty(this, "docs", {
914
- enumerable: true,
915
- configurable: true,
916
- writable: true,
917
- value: void 0
918
- });
919
- Object.defineProperty(this, "docsOrigin", {
920
- enumerable: true,
921
- configurable: true,
922
- writable: true,
923
- value: void 0
924
- });
925
- Object.defineProperty(this, "docsPath", {
926
- enumerable: true,
927
- configurable: true,
928
- writable: true,
929
- value: void 0
930
- });
931
- Object.defineProperty(this, "shortMessage", {
932
- enumerable: true,
933
- configurable: true,
934
- writable: true,
935
- value: void 0
936
- });
937
- Object.defineProperty(this, "showVersion", {
938
- enumerable: true,
939
- configurable: true,
940
- writable: true,
941
- value: void 0
942
- });
943
- Object.defineProperty(this, "version", {
944
- enumerable: true,
945
- configurable: true,
946
- writable: true,
947
- value: void 0
948
- });
949
- Object.defineProperty(this, "cause", {
950
- enumerable: true,
951
- configurable: true,
952
- writable: true,
953
- value: void 0
954
- });
955
- Object.defineProperty(this, "name", {
956
- enumerable: true,
957
- configurable: true,
958
- writable: true,
959
- value: "BaseError"
960
- });
961
- this.cause = options.cause;
962
- this.details = details;
963
- this.docs = docs;
964
- this.docsOrigin = docsBaseUrl;
965
- this.docsPath = docsPath6;
966
- this.shortMessage = shortMessage;
967
- this.showVersion = showVersion;
968
- this.version = version3;
969
- }
970
- walk(fn) {
971
- return walk(this, fn);
972
- }
973
- };
974
- Object.defineProperty(BaseError3, "defaultStaticOptions", {
975
- enumerable: true,
976
- configurable: true,
977
- writable: true,
978
- value: {
979
- docsOrigin: "https://oxlib.sh",
980
- showVersion: false,
981
- version: `ox@${getVersion()}`
982
- }
983
- });
984
- (() => {
985
- BaseError3.setStaticOptions(BaseError3.defaultStaticOptions);
986
- })();
987
- function walk(err, fn) {
988
- if (fn?.(err))
989
- return err;
990
- if (err && typeof err === "object" && "cause" in err && err.cause)
991
- return walk(err.cause, fn);
992
- return fn ? null : err;
993
- }
994
-
995
- // node_modules/.pnpm/ox@0.14.30_typescript@6.0.3_zod@4.4.3/node_modules/ox/_esm/core/internal/bytes.js
996
- function assertSize2(bytes, size_) {
997
- if (size2(bytes) > size_)
998
- throw new SizeOverflowError({
999
- givenSize: size2(bytes),
1000
- maxSize: size_
1001
- });
1002
- }
1003
- function assertStartOffset(value, start) {
1004
- if (typeof start === "number" && start > 0 && start > size2(value) - 1)
1005
- throw new SliceOffsetOutOfBoundsError({
1006
- offset: start,
1007
- position: "start",
1008
- size: size2(value)
1009
- });
1010
- }
1011
- function assertEndOffset(value, start, end) {
1012
- if (typeof start === "number" && typeof end === "number" && size2(value) !== end - start) {
1013
- throw new SliceOffsetOutOfBoundsError({
1014
- offset: end,
1015
- position: "end",
1016
- size: size2(value)
1017
- });
1018
- }
1019
- }
1020
- var charCodeMap = {
1021
- zero: 48,
1022
- nine: 57,
1023
- A: 65,
1024
- F: 70,
1025
- a: 97,
1026
- f: 102
1027
- };
1028
- function charCodeToBase16(char) {
1029
- if (char >= charCodeMap.zero && char <= charCodeMap.nine)
1030
- return char - charCodeMap.zero;
1031
- if (char >= charCodeMap.A && char <= charCodeMap.F)
1032
- return char - (charCodeMap.A - 10);
1033
- if (char >= charCodeMap.a && char <= charCodeMap.f)
1034
- return char - (charCodeMap.a - 10);
1035
- return void 0;
1036
- }
1037
- function pad(bytes, options = {}) {
1038
- const { dir, size: size4 = 32 } = options;
1039
- if (size4 === 0)
1040
- return bytes;
1041
- if (bytes.length > size4)
1042
- throw new SizeExceedsPaddingSizeError({
1043
- size: bytes.length,
1044
- targetSize: size4,
1045
- type: "Bytes"
1046
- });
1047
- const paddedBytes = new Uint8Array(size4);
1048
- for (let i = 0; i < size4; i++) {
1049
- const padEnd = dir === "right";
1050
- paddedBytes[padEnd ? i : size4 - i - 1] = bytes[padEnd ? i : bytes.length - i - 1];
1051
- }
1052
- return paddedBytes;
1053
- }
1054
- function trim2(value, options = {}) {
1055
- const { dir = "left" } = options;
1056
- let data = value;
1057
- let sliceLength = 0;
1058
- for (let i = 0; i < data.length - 1; i++) {
1059
- if (data[dir === "left" ? i : data.length - i - 1].toString() === "0")
1060
- sliceLength++;
1061
- else
1062
- break;
1063
- }
1064
- data = dir === "left" ? data.slice(sliceLength) : data.slice(0, data.length - sliceLength);
1065
- return data;
1066
- }
1067
-
1068
- // node_modules/.pnpm/ox@0.14.30_typescript@6.0.3_zod@4.4.3/node_modules/ox/_esm/core/internal/hex.js
1069
- function assertSize3(hex, size_) {
1070
- if (size3(hex) > size_)
1071
- throw new SizeOverflowError2({
1072
- givenSize: size3(hex),
1073
- maxSize: size_
1074
- });
1075
- }
1076
- function assertStartOffset2(value, start) {
1077
- if (typeof start === "number" && start > 0 && start > size3(value) - 1)
1078
- throw new SliceOffsetOutOfBoundsError2({
1079
- offset: start,
1080
- position: "start",
1081
- size: size3(value)
1082
- });
1083
- }
1084
- function assertEndOffset2(value, start, end) {
1085
- if (typeof start === "number" && typeof end === "number" && size3(value) !== end - start) {
1086
- throw new SliceOffsetOutOfBoundsError2({
1087
- offset: end,
1088
- position: "end",
1089
- size: size3(value)
1090
- });
1091
- }
1092
- }
1093
- function pad2(hex_, options = {}) {
1094
- const { dir, size: size4 = 32 } = options;
1095
- if (size4 === 0)
1096
- return hex_;
1097
- const hex = hex_.replace("0x", "");
1098
- if (hex.length > size4 * 2)
1099
- throw new SizeExceedsPaddingSizeError2({
1100
- size: Math.ceil(hex.length / 2),
1101
- targetSize: size4,
1102
- type: "Hex"
1103
- });
1104
- return `0x${hex[dir === "right" ? "padEnd" : "padStart"](size4 * 2, "0")}`;
1105
- }
1106
- function trim3(value, options = {}) {
1107
- const { dir = "left" } = options;
1108
- let data = value.replace("0x", "");
1109
- let sliceLength = 0;
1110
- for (let i = 0; i < data.length - 1; i++) {
1111
- if (data[dir === "left" ? i : data.length - i - 1].toString() === "0")
1112
- sliceLength++;
1113
- else
1114
- break;
1115
- }
1116
- data = dir === "left" ? data.slice(sliceLength) : data.slice(0, data.length - sliceLength);
1117
- if (data === "0")
1118
- return "0x";
1119
- if (dir === "right" && data.length % 2 === 1)
1120
- return `0x${data}0`;
1121
- return `0x${data}`;
1122
- }
1123
-
1124
- // node_modules/.pnpm/ox@0.14.30_typescript@6.0.3_zod@4.4.3/node_modules/ox/_esm/core/Json.js
1125
- var bigIntSuffix = "#__bigint";
1126
- function stringify2(value, replacer, space) {
1127
- return JSON.stringify(value, (key, value2) => {
1128
- if (typeof replacer === "function")
1129
- return replacer(key, value2);
1130
- if (typeof value2 === "bigint")
1131
- return value2.toString() + bigIntSuffix;
1132
- return value2;
1133
- }, space);
1134
- }
1135
-
1136
- // node_modules/.pnpm/ox@0.14.30_typescript@6.0.3_zod@4.4.3/node_modules/ox/_esm/core/Bytes.js
1137
- var decoder = /* @__PURE__ */ new TextDecoder();
1138
- var encoder = /* @__PURE__ */ new TextEncoder();
1139
- function assert(value) {
1140
- if (value instanceof Uint8Array)
1141
- return;
1142
- if (!value)
1143
- throw new InvalidBytesTypeError(value);
1144
- if (typeof value !== "object")
1145
- throw new InvalidBytesTypeError(value);
1146
- if (!("BYTES_PER_ELEMENT" in value))
1147
- throw new InvalidBytesTypeError(value);
1148
- if (value.BYTES_PER_ELEMENT !== 1 || value.constructor.name !== "Uint8Array")
1149
- throw new InvalidBytesTypeError(value);
1150
- }
1151
- function from(value) {
1152
- if (value instanceof Uint8Array)
1153
- return value;
1154
- if (typeof value === "string")
1155
- return fromHex(value);
1156
- return fromArray(value);
1157
- }
1158
- function fromArray(value) {
1159
- return value instanceof Uint8Array ? value : new Uint8Array(value);
1160
- }
1161
- function fromHex(value, options = {}) {
1162
- const { size: size4 } = options;
1163
- let hex = value;
1164
- if (size4) {
1165
- assertSize3(value, size4);
1166
- hex = padRight(value, size4);
1167
- }
1168
- let hexString = hex.slice(2);
1169
- if (hexString.length % 2)
1170
- hexString = `0${hexString}`;
1171
- const length = hexString.length / 2;
1172
- const bytes = new Uint8Array(length);
1173
- for (let index = 0, j = 0; index < length; index++) {
1174
- const nibbleLeft = charCodeToBase16(hexString.charCodeAt(j++));
1175
- const nibbleRight = charCodeToBase16(hexString.charCodeAt(j++));
1176
- if (nibbleLeft === void 0 || nibbleRight === void 0) {
1177
- throw new BaseError3(`Invalid byte sequence ("${hexString[j - 2]}${hexString[j - 1]}" in "${hexString}").`);
1178
- }
1179
- bytes[index] = nibbleLeft << 4 | nibbleRight;
1180
- }
1181
- return bytes;
1182
- }
1183
- function fromString(value, options = {}) {
1184
- const { size: size4 } = options;
1185
- const bytes = encoder.encode(value);
1186
- if (typeof size4 === "number") {
1187
- assertSize2(bytes, size4);
1188
- return padRight2(bytes, size4);
1189
- }
1190
- return bytes;
1191
- }
1192
- function padRight2(value, size4) {
1193
- return pad(value, { dir: "right", size: size4 });
1194
- }
1195
- function size2(value) {
1196
- return value.length;
1197
- }
1198
- function slice2(value, start, end, options = {}) {
1199
- const { strict } = options;
1200
- assertStartOffset(value, start);
1201
- const value_ = value.slice(start, end);
1202
- if (strict)
1203
- assertEndOffset(value_, start, end);
1204
- return value_;
1205
- }
1206
- function toBigInt2(bytes, options = {}) {
1207
- const { size: size4 } = options;
1208
- if (typeof size4 !== "undefined")
1209
- assertSize2(bytes, size4);
1210
- const hex = fromBytes(bytes, options);
1211
- return toBigInt(hex, options);
1212
- }
1213
- function toBoolean(bytes, options = {}) {
1214
- const { size: size4 } = options;
1215
- let bytes_ = bytes;
1216
- if (typeof size4 !== "undefined") {
1217
- assertSize2(bytes_, size4);
1218
- bytes_ = trimLeft(bytes_);
1219
- }
1220
- if (bytes_.length > 1 || bytes_[0] > 1)
1221
- throw new InvalidBytesBooleanError2(bytes_);
1222
- return Boolean(bytes_[0]);
1223
- }
1224
- function toNumber2(bytes, options = {}) {
1225
- const { size: size4 } = options;
1226
- if (typeof size4 !== "undefined")
1227
- assertSize2(bytes, size4);
1228
- const hex = fromBytes(bytes, options);
1229
- return toNumber(hex, options);
1230
- }
1231
- function toString(bytes, options = {}) {
1232
- const { size: size4 } = options;
1233
- let bytes_ = bytes;
1234
- if (typeof size4 !== "undefined") {
1235
- assertSize2(bytes_, size4);
1236
- bytes_ = trimRight(bytes_);
1237
- }
1238
- return decoder.decode(bytes_);
1239
- }
1240
- function trimLeft(value) {
1241
- return trim2(value, { dir: "left" });
1242
- }
1243
- function trimRight(value) {
1244
- return trim2(value, { dir: "right" });
1245
- }
1246
- function validate(value) {
1247
- try {
1248
- assert(value);
1249
- return true;
1250
- } catch {
1251
- return false;
1252
- }
1253
- }
1254
- var InvalidBytesBooleanError2 = class extends BaseError3 {
1255
- constructor(bytes) {
1256
- super(`Bytes value \`${bytes}\` is not a valid boolean.`, {
1257
- metaMessages: [
1258
- "The bytes array must contain a single byte of either a `0` or `1` value."
1259
- ]
1260
- });
1261
- Object.defineProperty(this, "name", {
1262
- enumerable: true,
1263
- configurable: true,
1264
- writable: true,
1265
- value: "Bytes.InvalidBytesBooleanError"
1266
- });
1267
- }
1268
- };
1269
- var InvalidBytesTypeError = class extends BaseError3 {
1270
- constructor(value) {
1271
- super(`Value \`${typeof value === "object" ? stringify2(value) : value}\` of type \`${typeof value}\` is an invalid Bytes value.`, {
1272
- metaMessages: ["Bytes values must be of type `Bytes`."]
1273
- });
1274
- Object.defineProperty(this, "name", {
1275
- enumerable: true,
1276
- configurable: true,
1277
- writable: true,
1278
- value: "Bytes.InvalidBytesTypeError"
1279
- });
1280
- }
1281
- };
1282
- var SizeOverflowError = class extends BaseError3 {
1283
- constructor({ givenSize, maxSize }) {
1284
- super(`Size cannot exceed \`${maxSize}\` bytes. Given size: \`${givenSize}\` bytes.`);
1285
- Object.defineProperty(this, "name", {
1286
- enumerable: true,
1287
- configurable: true,
1288
- writable: true,
1289
- value: "Bytes.SizeOverflowError"
1290
- });
1291
- }
1292
- };
1293
- var SliceOffsetOutOfBoundsError = class extends BaseError3 {
1294
- constructor({ offset, position, size: size4 }) {
1295
- super(`Slice ${position === "start" ? "starting" : "ending"} at offset \`${offset}\` is out-of-bounds (size: \`${size4}\`).`);
1296
- Object.defineProperty(this, "name", {
1297
- enumerable: true,
1298
- configurable: true,
1299
- writable: true,
1300
- value: "Bytes.SliceOffsetOutOfBoundsError"
1301
- });
1302
- }
1303
- };
1304
- var SizeExceedsPaddingSizeError = class extends BaseError3 {
1305
- constructor({ size: size4, targetSize, type }) {
1306
- super(`${type.charAt(0).toUpperCase()}${type.slice(1).toLowerCase()} size (\`${size4}\`) exceeds padding size (\`${targetSize}\`).`);
1307
- Object.defineProperty(this, "name", {
1308
- enumerable: true,
1309
- configurable: true,
1310
- writable: true,
1311
- value: "Bytes.SizeExceedsPaddingSizeError"
1312
- });
1313
- }
1314
- };
1315
-
1316
- // node_modules/.pnpm/ox@0.14.30_typescript@6.0.3_zod@4.4.3/node_modules/ox/_esm/core/Hex.js
1317
- var encoder2 = /* @__PURE__ */ new TextEncoder();
1318
- var hexes = /* @__PURE__ */ Array.from({ length: 256 }, (_v, i) => i.toString(16).padStart(2, "0"));
1319
- function assert2(value, options = {}) {
1320
- const { strict = false } = options;
1321
- if (!value)
1322
- throw new InvalidHexTypeError(value);
1323
- if (typeof value !== "string")
1324
- throw new InvalidHexTypeError(value);
1325
- if (strict) {
1326
- if (!/^0x[0-9a-fA-F]*$/.test(value))
1327
- throw new InvalidHexValueError(value);
1328
- }
1329
- if (!value.startsWith("0x"))
1330
- throw new InvalidHexValueError(value);
1331
- }
1332
- function concat2(...values) {
1333
- return `0x${values.reduce((acc, x) => acc + x.replace("0x", ""), "")}`;
1334
- }
1335
- function from2(value) {
1336
- if (value instanceof Uint8Array)
1337
- return fromBytes(value);
1338
- if (Array.isArray(value))
1339
- return fromBytes(new Uint8Array(value));
1340
- return value;
1341
- }
1342
- function fromBoolean(value, options = {}) {
1343
- const hex = `0x${Number(value)}`;
1344
- if (typeof options.size === "number") {
1345
- assertSize3(hex, options.size);
1346
- return padLeft(hex, options.size);
1347
- }
1348
- return hex;
1349
- }
1350
- function fromBytes(value, options = {}) {
1351
- let string = "";
1352
- for (let i = 0; i < value.length; i++)
1353
- string += hexes[value[i]];
1354
- const hex = `0x${string}`;
1355
- if (typeof options.size === "number") {
1356
- assertSize3(hex, options.size);
1357
- return padRight(hex, options.size);
1358
- }
1359
- return hex;
1360
- }
1361
- function fromNumber(value, options = {}) {
1362
- const { signed, size: size4 } = options;
1363
- const value_ = BigInt(value);
1364
- let maxValue;
1365
- if (size4) {
1366
- if (signed)
1367
- maxValue = (1n << BigInt(size4) * 8n - 1n) - 1n;
1368
- else
1369
- maxValue = 2n ** (BigInt(size4) * 8n) - 1n;
1370
- } else if (typeof value === "number") {
1371
- maxValue = BigInt(Number.MAX_SAFE_INTEGER);
1372
- }
1373
- const minValue = typeof maxValue === "bigint" && signed ? -maxValue - 1n : 0;
1374
- if (maxValue && value_ > maxValue || value_ < minValue) {
1375
- const suffix = typeof value === "bigint" ? "n" : "";
1376
- throw new IntegerOutOfRangeError({
1377
- max: maxValue ? `${maxValue}${suffix}` : void 0,
1378
- min: `${minValue}${suffix}`,
1379
- signed,
1380
- size: size4,
1381
- value: `${value}${suffix}`
1382
- });
1383
- }
1384
- const stringValue = (signed && value_ < 0 ? BigInt.asUintN(size4 * 8, BigInt(value_)) : value_).toString(16);
1385
- const hex = `0x${stringValue}`;
1386
- if (size4)
1387
- return padLeft(hex, size4);
1388
- return hex;
1389
- }
1390
- function fromString2(value, options = {}) {
1391
- return fromBytes(encoder2.encode(value), options);
1392
- }
1393
- function padLeft(value, size4) {
1394
- return pad2(value, { dir: "left", size: size4 });
1395
- }
1396
- function padRight(value, size4) {
1397
- return pad2(value, { dir: "right", size: size4 });
1398
- }
1399
- function slice3(value, start, end, options = {}) {
1400
- const { strict } = options;
1401
- assertStartOffset2(value, start);
1402
- const value_ = `0x${value.replace("0x", "").slice((start ?? 0) * 2, (end ?? value.length) * 2)}`;
1403
- if (strict)
1404
- assertEndOffset2(value_, start, end);
1405
- return value_;
1406
- }
1407
- function size3(value) {
1408
- return Math.ceil((value.length - 2) / 2);
1409
- }
1410
- function trimLeft2(value) {
1411
- return trim3(value, { dir: "left" });
1412
- }
1413
- function toBigInt(hex, options = {}) {
1414
- const { signed } = options;
1415
- if (options.size)
1416
- assertSize3(hex, options.size);
1417
- const value = BigInt(hex);
1418
- if (!signed)
1419
- return value;
1420
- const size4 = (hex.length - 2) / 2;
1421
- const max_unsigned = (1n << BigInt(size4) * 8n) - 1n;
1422
- const max_signed = max_unsigned >> 1n;
1423
- if (value <= max_signed)
1424
- return value;
1425
- return value - max_unsigned - 1n;
1426
- }
1427
- function toNumber(hex, options = {}) {
1428
- const { signed, size: size4 } = options;
1429
- if (!signed && !size4)
1430
- return Number(hex);
1431
- return Number(toBigInt(hex, options));
1432
- }
1433
- function validate2(value, options = {}) {
1434
- const { strict = false } = options;
1435
- try {
1436
- assert2(value, { strict });
1437
- return true;
1438
- } catch {
1439
- return false;
1440
- }
1441
- }
1442
- var IntegerOutOfRangeError = class extends BaseError3 {
1443
- constructor({ max, min, signed, size: size4, value }) {
1444
- super(`Number \`${value}\` is not in safe${size4 ? ` ${size4 * 8}-bit` : ""}${signed ? " signed" : " unsigned"} integer range ${max ? `(\`${min}\` to \`${max}\`)` : `(above \`${min}\`)`}`);
1445
- Object.defineProperty(this, "name", {
1446
- enumerable: true,
1447
- configurable: true,
1448
- writable: true,
1449
- value: "Hex.IntegerOutOfRangeError"
1450
- });
1451
- }
1452
- };
1453
- var InvalidHexTypeError = class extends BaseError3 {
1454
- constructor(value) {
1455
- super(`Value \`${typeof value === "object" ? stringify2(value) : value}\` of type \`${typeof value}\` is an invalid hex type.`, {
1456
- metaMessages: ['Hex types must be represented as `"0x${string}"`.']
1457
- });
1458
- Object.defineProperty(this, "name", {
1459
- enumerable: true,
1460
- configurable: true,
1461
- writable: true,
1462
- value: "Hex.InvalidHexTypeError"
1463
- });
1464
- }
1465
- };
1466
- var InvalidHexValueError = class extends BaseError3 {
1467
- constructor(value) {
1468
- super(`Value \`${value}\` is an invalid hex value.`, {
1469
- metaMessages: [
1470
- 'Hex values must start with `"0x"` and contain only hexadecimal characters (0-9, a-f, A-F).'
1471
- ]
1472
- });
1473
- Object.defineProperty(this, "name", {
1474
- enumerable: true,
1475
- configurable: true,
1476
- writable: true,
1477
- value: "Hex.InvalidHexValueError"
1478
- });
1479
- }
1480
- };
1481
- var SizeOverflowError2 = class extends BaseError3 {
1482
- constructor({ givenSize, maxSize }) {
1483
- super(`Size cannot exceed \`${maxSize}\` bytes. Given size: \`${givenSize}\` bytes.`);
1484
- Object.defineProperty(this, "name", {
1485
- enumerable: true,
1486
- configurable: true,
1487
- writable: true,
1488
- value: "Hex.SizeOverflowError"
1489
- });
1490
- }
1491
- };
1492
- var SliceOffsetOutOfBoundsError2 = class extends BaseError3 {
1493
- constructor({ offset, position, size: size4 }) {
1494
- super(`Slice ${position === "start" ? "starting" : "ending"} at offset \`${offset}\` is out-of-bounds (size: \`${size4}\`).`);
1495
- Object.defineProperty(this, "name", {
1496
- enumerable: true,
1497
- configurable: true,
1498
- writable: true,
1499
- value: "Hex.SliceOffsetOutOfBoundsError"
1500
- });
1501
- }
1502
- };
1503
- var SizeExceedsPaddingSizeError2 = class extends BaseError3 {
1504
- constructor({ size: size4, targetSize, type }) {
1505
- super(`${type.charAt(0).toUpperCase()}${type.slice(1).toLowerCase()} size (\`${size4}\`) exceeds padding size (\`${targetSize}\`).`);
1506
- Object.defineProperty(this, "name", {
1507
- enumerable: true,
1508
- configurable: true,
1509
- writable: true,
1510
- value: "Hex.SizeExceedsPaddingSizeError"
1511
- });
1512
- }
1513
- };
1514
-
1515
859
  // node_modules/.pnpm/ox@0.14.30_typescript@6.0.3_zod@4.4.3/node_modules/ox/_esm/core/Withdrawal.js
1516
860
  function toRpc(withdrawal) {
1517
861
  return {
@@ -2347,8 +1691,8 @@ function decodeBool(cursor) {
2347
1691
  return [bytesToBool(cursor.readBytes(32), { size: 32 }), 32];
2348
1692
  }
2349
1693
  function decodeBytes(cursor, param, { staticPosition }) {
2350
- const [_, size4] = param.type.split("bytes");
2351
- if (!size4) {
1694
+ const [_, size2] = param.type.split("bytes");
1695
+ if (!size2) {
2352
1696
  const offset = bytesToNumber(cursor.readBytes(32));
2353
1697
  cursor.setPosition(staticPosition + offset);
2354
1698
  const length = bytesToNumber(cursor.readBytes(32));
@@ -2360,15 +1704,15 @@ function decodeBytes(cursor, param, { staticPosition }) {
2360
1704
  cursor.setPosition(staticPosition + 32);
2361
1705
  return [bytesToHex(data), 32];
2362
1706
  }
2363
- const value = bytesToHex(cursor.readBytes(Number.parseInt(size4, 10), 32));
1707
+ const value = bytesToHex(cursor.readBytes(Number.parseInt(size2, 10), 32));
2364
1708
  return [value, 32];
2365
1709
  }
2366
1710
  function decodeNumber(cursor, param) {
2367
1711
  const signed = param.type.startsWith("int");
2368
- const size4 = Number.parseInt(param.type.split("int")[1] || "256", 10);
1712
+ const size2 = Number.parseInt(param.type.split("int")[1] || "256", 10);
2369
1713
  const value = cursor.readBytes(32);
2370
1714
  return [
2371
- size4 > 48 ? bytesToBigInt(value, { signed }) : bytesToNumber(value, { signed }),
1715
+ size2 > 48 ? bytesToBigInt(value, { signed }) : bytesToNumber(value, { signed }),
2372
1716
  32
2373
1717
  ];
2374
1718
  }
@@ -3051,9 +2395,9 @@ var HttpRequestError = class extends BaseError {
3051
2395
  }
3052
2396
  };
3053
2397
  var ResponseBodyTooLargeError = class extends BaseError {
3054
- constructor({ maxSize, size: size4 }) {
2398
+ constructor({ maxSize, size: size2 }) {
3055
2399
  super("HTTP response body exceeded the size limit.", {
3056
- metaMessages: [`Max: ${maxSize} bytes`, `Received: ${size4} bytes`],
2400
+ metaMessages: [`Max: ${maxSize} bytes`, `Received: ${size2} bytes`],
3057
2401
  name: "ResponseBodyTooLargeError"
3058
2402
  });
3059
2403
  Object.defineProperty(this, "maxSize", {
@@ -3069,7 +2413,7 @@ var ResponseBodyTooLargeError = class extends BaseError {
3069
2413
  value: void 0
3070
2414
  });
3071
2415
  this.maxSize = maxSize;
3072
- this.size = size4;
2416
+ this.size = size2;
3073
2417
  }
3074
2418
  };
3075
2419
  var RpcRequestError = class extends BaseError {
@@ -3955,7 +3299,7 @@ async function call(client, args) {
3955
3299
  if (isAbortError(err))
3956
3300
  throw err;
3957
3301
  const data2 = getRevertErrorData(err);
3958
- const { offchainLookup: offchainLookup2, offchainLookupSignature: offchainLookupSignature2 } = await import("./ccip-FXWZDDF5.js");
3302
+ const { offchainLookup: offchainLookup2, offchainLookupSignature: offchainLookupSignature2 } = await import("./ccip-UCLT5VOW.js");
3959
3303
  if (client.ccipRead !== false && data2?.slice(0, 10) === offchainLookupSignature2 && to)
3960
3304
  return {
3961
3305
  data: await offchainLookup2(client, { data: data2, requestOptions, to })
@@ -4012,8 +3356,8 @@ async function scheduleMulticall(client, args) {
4012
3356
  id: `${client.uid}.${blockId}.${getRequestOptionsId(requestOptions)}${stateOverrideKey}`,
4013
3357
  wait,
4014
3358
  shouldSplitBatch(args2) {
4015
- const size4 = args2.reduce((size5, { data: data2 }) => size5 + (data2.length - 2), 0);
4016
- return size4 > batchSize * 2;
3359
+ const size2 = args2.reduce((size3, { data: data2 }) => size3 + (data2.length - 2), 0);
3360
+ return size2 > batchSize * 2;
4017
3361
  },
4018
3362
  fn: async (requests) => {
4019
3363
  const calls = requests.map((request) => ({
@@ -4420,33 +3764,6 @@ export {
4420
3764
  assertRequest,
4421
3765
  isAddressEqual,
4422
3766
  decodeFunctionResult,
4423
- BaseError3 as BaseError,
4424
- stringify2 as stringify,
4425
- from,
4426
- fromHex,
4427
- fromString,
4428
- size2 as size,
4429
- slice2 as slice,
4430
- toBigInt2 as toBigInt,
4431
- toBoolean,
4432
- toNumber2 as toNumber,
4433
- toString,
4434
- trimLeft,
4435
- validate,
4436
- concat2 as concat,
4437
- from2,
4438
- fromBoolean,
4439
- fromBytes,
4440
- fromNumber,
4441
- fromString2,
4442
- padLeft,
4443
- padRight,
4444
- slice3 as slice2,
4445
- size3 as size2,
4446
- trimLeft2,
4447
- toNumber as toNumber2,
4448
- validate2,
4449
- IntegerOutOfRangeError,
4450
3767
  toRpc2 as toRpc,
4451
3768
  multicall3Abi,
4452
3769
  universalResolverResolveAbi,
@@ -4471,4 +3788,4 @@ export {
4471
3788
  ccipRequest,
4472
3789
  call
4473
3790
  };
4474
- //# sourceMappingURL=chunk-WOHCAMDQ.js.map
3791
+ //# sourceMappingURL=chunk-LPRVHM7P.js.map