@xyo-network/hash 5.4.0 → 5.5.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
|
@@ -1,55 +1,9 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
(() => {
|
|
3
|
-
|
|
4
|
-
var __defProp = Object.defineProperty;
|
|
5
|
-
var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
|
|
6
|
-
var __getOwnPropNames = Object.getOwnPropertyNames;
|
|
7
|
-
var __getProtoOf = Object.getPrototypeOf;
|
|
8
|
-
var __hasOwnProp = Object.prototype.hasOwnProperty;
|
|
9
|
-
var __commonJS = (cb, mod) => function __require() {
|
|
10
|
-
return mod || (0, cb[__getOwnPropNames(cb)[0]])((mod = { exports: {} }).exports, mod), mod.exports;
|
|
11
|
-
};
|
|
12
|
-
var __copyProps = (to, from, except, desc) => {
|
|
13
|
-
if (from && typeof from === "object" || typeof from === "function") {
|
|
14
|
-
for (let key of __getOwnPropNames(from))
|
|
15
|
-
if (!__hasOwnProp.call(to, key) && key !== except)
|
|
16
|
-
__defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
|
|
17
|
-
}
|
|
18
|
-
return to;
|
|
19
|
-
};
|
|
20
|
-
var __toESM = (mod, isNodeMode, target) => (target = mod != null ? __create(__getProtoOf(mod)) : {}, __copyProps(
|
|
21
|
-
// If the importer is in node compatibility mode or this is not an ESM
|
|
22
|
-
// file that has been converted to a CommonJS file using a Babel-
|
|
23
|
-
// compatible transform (i.e. "__esModule" has not been set), then set
|
|
24
|
-
// "default" to the CommonJS "module.exports" for node compatibility.
|
|
25
|
-
isNodeMode || !mod || !mod.__esModule ? __defProp(target, "default", { value: mod, enumerable: true }) : target,
|
|
26
|
-
mod
|
|
27
|
-
));
|
|
28
|
-
|
|
29
|
-
// ../../../../../../node_modules/.pnpm/is-observable@2.1.0/node_modules/is-observable/index.js
|
|
30
|
-
var require_is_observable = __commonJS({
|
|
31
|
-
"../../../../../../node_modules/.pnpm/is-observable@2.1.0/node_modules/is-observable/index.js"(exports, module) {
|
|
32
|
-
"use strict";
|
|
33
|
-
module.exports = (value) => {
|
|
34
|
-
if (!value) {
|
|
35
|
-
return false;
|
|
36
|
-
}
|
|
37
|
-
if (typeof Symbol.observable === "symbol" && typeof value[Symbol.observable] === "function") {
|
|
38
|
-
return value === value[Symbol.observable]();
|
|
39
|
-
}
|
|
40
|
-
if (typeof value["@@observable"] === "function") {
|
|
41
|
-
return value === value["@@observable"]();
|
|
42
|
-
}
|
|
43
|
-
return false;
|
|
44
|
-
};
|
|
45
|
-
}
|
|
46
|
-
});
|
|
47
|
-
|
|
48
|
-
// ../../../../../../node_modules/.pnpm/@xylabs+platform@5.0.97/node_modules/@xylabs/platform/dist/browser/index-browser.mjs
|
|
3
|
+
// ../../../../../../node_modules/.pnpm/@xylabs+platform@5.0.99/node_modules/@xylabs/platform/dist/browser/index-browser.mjs
|
|
49
4
|
var subtle = globalThis.crypto.subtle;
|
|
50
5
|
|
|
51
|
-
// ../../../../../../node_modules/.pnpm/@xylabs+threads@5.0.
|
|
52
|
-
var import_is_observable_2_1_0 = __toESM(require_is_observable(), 1);
|
|
6
|
+
// ../../../../../../node_modules/.pnpm/@xylabs+threads@5.0.99_debug@4.4.3_observable-fns@0.6.1/node_modules/@xylabs/threads/dist/browser/worker/worker.browser.mjs
|
|
53
7
|
var DefaultErrorSerializer = {
|
|
54
8
|
deserialize(message) {
|
|
55
9
|
return Object.assign(new Error(message.message), {
|
|
@@ -82,6 +36,18 @@
|
|
|
82
36
|
function serialize(input) {
|
|
83
37
|
return globalThis.registeredSerializer.serialize(input);
|
|
84
38
|
}
|
|
39
|
+
var isSomeObservable = (value) => {
|
|
40
|
+
if (!value) {
|
|
41
|
+
return false;
|
|
42
|
+
}
|
|
43
|
+
if (typeof Symbol.observable === "symbol" && typeof value[Symbol.observable] === "function") {
|
|
44
|
+
return value === value[Symbol.observable]();
|
|
45
|
+
}
|
|
46
|
+
if (typeof value["@@observable"] === "function") {
|
|
47
|
+
return value === value["@@observable"]();
|
|
48
|
+
}
|
|
49
|
+
return false;
|
|
50
|
+
};
|
|
85
51
|
var $transferable = /* @__PURE__ */ Symbol("thread.transferable");
|
|
86
52
|
function isTransferDescriptor(thing) {
|
|
87
53
|
return thing && typeof thing === "object" && thing[$transferable];
|
|
@@ -92,7 +58,7 @@
|
|
|
92
58
|
const activeSubscriptions = /* @__PURE__ */ new Map();
|
|
93
59
|
const isMasterJobCancelMessage = (thing) => thing?.type === "cancel";
|
|
94
60
|
const isMasterJobRunMessage = (thing) => thing?.type === "run";
|
|
95
|
-
const isObservable = (thing) => (
|
|
61
|
+
const isObservable = (thing) => isSomeObservable(thing) || isZenObservable(thing);
|
|
96
62
|
function isZenObservable(thing) {
|
|
97
63
|
return thing && typeof thing === "object" && typeof thing.subscribe === "function";
|
|
98
64
|
}
|
|
@@ -1,55 +1,12 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
(() => {
|
|
3
|
-
var __create = Object.create;
|
|
4
3
|
var __defProp = Object.defineProperty;
|
|
5
|
-
var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
|
|
6
|
-
var __getOwnPropNames = Object.getOwnPropertyNames;
|
|
7
|
-
var __getProtoOf = Object.getPrototypeOf;
|
|
8
|
-
var __hasOwnProp = Object.prototype.hasOwnProperty;
|
|
9
|
-
var __commonJS = (cb, mod) => function __require() {
|
|
10
|
-
return mod || (0, cb[__getOwnPropNames(cb)[0]])((mod = { exports: {} }).exports, mod), mod.exports;
|
|
11
|
-
};
|
|
12
4
|
var __export = (target, all) => {
|
|
13
5
|
for (var name in all)
|
|
14
6
|
__defProp(target, name, { get: all[name], enumerable: true });
|
|
15
7
|
};
|
|
16
|
-
var __copyProps = (to, from, except, desc) => {
|
|
17
|
-
if (from && typeof from === "object" || typeof from === "function") {
|
|
18
|
-
for (let key of __getOwnPropNames(from))
|
|
19
|
-
if (!__hasOwnProp.call(to, key) && key !== except)
|
|
20
|
-
__defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
|
|
21
|
-
}
|
|
22
|
-
return to;
|
|
23
|
-
};
|
|
24
|
-
var __toESM = (mod, isNodeMode, target) => (target = mod != null ? __create(__getProtoOf(mod)) : {}, __copyProps(
|
|
25
|
-
// If the importer is in node compatibility mode or this is not an ESM
|
|
26
|
-
// file that has been converted to a CommonJS file using a Babel-
|
|
27
|
-
// compatible transform (i.e. "__esModule" has not been set), then set
|
|
28
|
-
// "default" to the CommonJS "module.exports" for node compatibility.
|
|
29
|
-
isNodeMode || !mod || !mod.__esModule ? __defProp(target, "default", { value: mod, enumerable: true }) : target,
|
|
30
|
-
mod
|
|
31
|
-
));
|
|
32
8
|
|
|
33
|
-
// ../../../../../../node_modules/.pnpm
|
|
34
|
-
var require_is_observable = __commonJS({
|
|
35
|
-
"../../../../../../node_modules/.pnpm/is-observable@2.1.0/node_modules/is-observable/index.js"(exports, module) {
|
|
36
|
-
"use strict";
|
|
37
|
-
module.exports = (value) => {
|
|
38
|
-
if (!value) {
|
|
39
|
-
return false;
|
|
40
|
-
}
|
|
41
|
-
if (typeof Symbol.observable === "symbol" && typeof value[Symbol.observable] === "function") {
|
|
42
|
-
return value === value[Symbol.observable]();
|
|
43
|
-
}
|
|
44
|
-
if (typeof value["@@observable"] === "function") {
|
|
45
|
-
return value === value["@@observable"]();
|
|
46
|
-
}
|
|
47
|
-
return false;
|
|
48
|
-
};
|
|
49
|
-
}
|
|
50
|
-
});
|
|
51
|
-
|
|
52
|
-
// ../../../../../../node_modules/.pnpm/@xylabs+typeof@5.0.97/node_modules/@xylabs/typeof/dist/neutral/index.mjs
|
|
9
|
+
// ../../../../../../node_modules/.pnpm/@xylabs+typeof@5.0.99/node_modules/@xylabs/typeof/dist/neutral/index.mjs
|
|
53
10
|
function isUndefined(value) {
|
|
54
11
|
return value === void 0;
|
|
55
12
|
}
|
|
@@ -4005,7 +3962,7 @@ Set the \`cycles\` parameter to \`"ref"\` to resolve cyclical schemas with defs.
|
|
|
4005
3962
|
return _superRefine(fn);
|
|
4006
3963
|
}
|
|
4007
3964
|
|
|
4008
|
-
// ../../../../../../node_modules/.pnpm/@xylabs+error@5.0.
|
|
3965
|
+
// ../../../../../../node_modules/.pnpm/@xylabs+error@5.0.99/node_modules/@xylabs/error/dist/neutral/index.mjs
|
|
4009
3966
|
var assertError = (value, assert2, defaultMessage) => {
|
|
4010
3967
|
if (!isUndefined(assert2)) {
|
|
4011
3968
|
const assertString = typeof assert2 === "string" ? assert2 : typeof assert2 === "boolean" ? defaultMessage : assert2(value, defaultMessage);
|
|
@@ -4016,7 +3973,7 @@ Set the \`cycles\` parameter to \`"ref"\` to resolve cyclical schemas with defs.
|
|
|
4016
3973
|
return void 0;
|
|
4017
3974
|
};
|
|
4018
3975
|
|
|
4019
|
-
// ../../../../../../node_modules/.pnpm/@xylabs+hex@5.0.
|
|
3976
|
+
// ../../../../../../node_modules/.pnpm/@xylabs+hex@5.0.99_zod@4.3.6/node_modules/@xylabs/hex/dist/neutral/index.mjs
|
|
4020
3977
|
var HexRegExMinMax = (minBytes = 0, maxBytes = Number.MAX_SAFE_INTEGER / 2) => {
|
|
4021
3978
|
return new RegExp(`^[a-f0-9]{${minBytes * 2},${maxBytes * 2}}$`);
|
|
4022
3979
|
};
|
|
@@ -4153,8 +4110,7 @@ Set the \`cycles\` parameter to \`"ref"\` to resolve cyclical schemas with defs.
|
|
|
4153
4110
|
var BigIntToJsonZod = bigint2().nonnegative().transform((x) => toHex(x));
|
|
4154
4111
|
var JsonToBigIntZod = string2().transform((x) => toHex(x)).transform((x) => hexToBigInt(x));
|
|
4155
4112
|
|
|
4156
|
-
// ../../../../../../node_modules/.pnpm/@xylabs+threads@5.0.
|
|
4157
|
-
var import_is_observable_2_1_0 = __toESM(require_is_observable(), 1);
|
|
4113
|
+
// ../../../../../../node_modules/.pnpm/@xylabs+threads@5.0.99_debug@4.4.3_observable-fns@0.6.1/node_modules/@xylabs/threads/dist/browser/worker/worker.browser.mjs
|
|
4158
4114
|
var DefaultErrorSerializer = {
|
|
4159
4115
|
deserialize(message) {
|
|
4160
4116
|
return Object.assign(new Error(message.message), {
|
|
@@ -4187,6 +4143,18 @@ Set the \`cycles\` parameter to \`"ref"\` to resolve cyclical schemas with defs.
|
|
|
4187
4143
|
function serialize(input) {
|
|
4188
4144
|
return globalThis.registeredSerializer.serialize(input);
|
|
4189
4145
|
}
|
|
4146
|
+
var isSomeObservable = (value) => {
|
|
4147
|
+
if (!value) {
|
|
4148
|
+
return false;
|
|
4149
|
+
}
|
|
4150
|
+
if (typeof Symbol.observable === "symbol" && typeof value[Symbol.observable] === "function") {
|
|
4151
|
+
return value === value[Symbol.observable]();
|
|
4152
|
+
}
|
|
4153
|
+
if (typeof value["@@observable"] === "function") {
|
|
4154
|
+
return value === value["@@observable"]();
|
|
4155
|
+
}
|
|
4156
|
+
return false;
|
|
4157
|
+
};
|
|
4190
4158
|
var $transferable = /* @__PURE__ */ Symbol("thread.transferable");
|
|
4191
4159
|
function isTransferDescriptor(thing) {
|
|
4192
4160
|
return thing && typeof thing === "object" && thing[$transferable];
|
|
@@ -4197,7 +4165,7 @@ Set the \`cycles\` parameter to \`"ref"\` to resolve cyclical schemas with defs.
|
|
|
4197
4165
|
const activeSubscriptions = /* @__PURE__ */ new Map();
|
|
4198
4166
|
const isMasterJobCancelMessage = (thing) => thing?.type === "cancel";
|
|
4199
4167
|
const isMasterJobRunMessage = (thing) => thing?.type === "run";
|
|
4200
|
-
const isObservable = (thing) => (
|
|
4168
|
+
const isObservable = (thing) => isSomeObservable(thing) || isZenObservable(thing);
|
|
4201
4169
|
function isZenObservable(thing) {
|
|
4202
4170
|
return thing && typeof thing === "object" && typeof thing.subscribe === "function";
|
|
4203
4171
|
}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@xyo-network/hash",
|
|
3
|
-
"version": "5.
|
|
3
|
+
"version": "5.5.0",
|
|
4
4
|
"description": "Primary SDK for using XYO Protocol 2.0",
|
|
5
5
|
"homepage": "https://xyo.network",
|
|
6
6
|
"bugs": {
|
|
@@ -47,32 +47,63 @@
|
|
|
47
47
|
"!**/*.test.*",
|
|
48
48
|
"README.md"
|
|
49
49
|
],
|
|
50
|
-
"dependencies": {
|
|
51
|
-
"@xylabs/threads": "~5.0.97",
|
|
52
|
-
"hash-wasm": "~4.12.0"
|
|
53
|
-
},
|
|
54
50
|
"devDependencies": {
|
|
51
|
+
"@inquirer/core": "~11.1.8",
|
|
55
52
|
"@opentelemetry/api": "^1.9.1",
|
|
53
|
+
"@opentelemetry/sdk-trace-base": "^2",
|
|
56
54
|
"@types/node": "^25.6.0",
|
|
57
|
-
"@xylabs/hex": "^5.0.
|
|
58
|
-
"@xylabs/platform": "^5.0.
|
|
59
|
-
"@xylabs/sdk-js": "^5.0.
|
|
60
|
-
"@xylabs/
|
|
61
|
-
"@xylabs/
|
|
62
|
-
"@xylabs/
|
|
63
|
-
"@xylabs/vitest-
|
|
55
|
+
"@xylabs/hex": "^5.0.99",
|
|
56
|
+
"@xylabs/platform": "^5.0.99",
|
|
57
|
+
"@xylabs/sdk-js": "^5.0.99",
|
|
58
|
+
"@xylabs/threads": "~5.0.99",
|
|
59
|
+
"@xylabs/toolchain": "~7.11.2",
|
|
60
|
+
"@xylabs/tsconfig": "~7.11.2",
|
|
61
|
+
"@xylabs/vitest-extended": "~5.0",
|
|
62
|
+
"@xylabs/vitest-matchers": "~5.0.99",
|
|
63
|
+
"async-mutex": "^0.5",
|
|
64
|
+
"bn.js": "^5",
|
|
65
|
+
"buffer": "^6",
|
|
66
|
+
"chalk": "^5",
|
|
67
|
+
"cosmiconfig": ">=9",
|
|
68
|
+
"cosmiconfig-typescript-loader": "~6.3.0",
|
|
69
|
+
"cpy": "~13.2.1",
|
|
70
|
+
"debug": "~4.4.3",
|
|
71
|
+
"deepmerge": "~4.3.1",
|
|
64
72
|
"esbuild": "~0.28.0",
|
|
73
|
+
"eslint": "^10.2.0",
|
|
74
|
+
"ethers": "^6",
|
|
75
|
+
"find-up": "~8.0.0",
|
|
76
|
+
"get-tsconfig": "~4.13.7",
|
|
77
|
+
"glob": "~13.0.6",
|
|
78
|
+
"hash-wasm": "~4.12.0",
|
|
79
|
+
"license-checker": "~25.0.1",
|
|
80
|
+
"observable-fns": "~0.6.1",
|
|
65
81
|
"pako": "~2.1.0",
|
|
82
|
+
"parse-git-config": "~3.0.0",
|
|
83
|
+
"picomatch": "~4.0.4",
|
|
66
84
|
"publint": "~0.3.18",
|
|
85
|
+
"rollup": "~4.60.1",
|
|
86
|
+
"rollup-plugin-dts": "~6.4.1",
|
|
87
|
+
"rollup-plugin-node-externals": "~9.0.1",
|
|
88
|
+
"semver": "~7.7.4",
|
|
89
|
+
"sort-package-json": "~3.6.1",
|
|
90
|
+
"tsup": "~8.5.1",
|
|
91
|
+
"types-package-json": "~2.0.39",
|
|
67
92
|
"typescript": "~5.9.3",
|
|
68
93
|
"vite": "^8.0.8",
|
|
69
|
-
"vitest": "~4.1.
|
|
94
|
+
"vitest": "~4.1.5",
|
|
95
|
+
"wasm-feature-detect": "~1.8.0",
|
|
96
|
+
"yargs": "~18.0.0",
|
|
70
97
|
"zod": "^4.3.6",
|
|
71
|
-
"@xyo-network/wasm": "~5.
|
|
98
|
+
"@xyo-network/wasm": "~5.5.0"
|
|
72
99
|
},
|
|
73
100
|
"peerDependencies": {
|
|
74
|
-
"@xylabs/sdk-js": "^5.0.
|
|
75
|
-
"@
|
|
101
|
+
"@xylabs/sdk-js": "^5.0.99",
|
|
102
|
+
"@xylabs/threads": "~5.0.99",
|
|
103
|
+
"@xyo-network/wasm": "~5.5",
|
|
104
|
+
"debug": "~4.4.3",
|
|
105
|
+
"hash-wasm": "~4.12.0",
|
|
106
|
+
"observable-fns": "~0.6.1"
|
|
76
107
|
},
|
|
77
108
|
"publishConfig": {
|
|
78
109
|
"access": "public"
|