@calimero-network/mero-js 23.7.0 → 23.8.2
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.
- package/dist/cloud/cloud-client.d.ts +15 -0
- package/dist/cloud/cloud-client.js +6 -0
- package/dist/index.browser.mjs +2 -2
- package/dist/index.browser.mjs.map +3 -3
- package/dist/index.cjs +8 -2
- package/dist/index.cjs.map +2 -2
- package/dist/index.mjs +8 -2
- package/dist/index.mjs.map +2 -2
- package/dist/namespace-op/namespace-op.d.ts +6 -1
- package/dist/namespace-op/namespace-op.js +6 -1
- package/package.json +1 -1
package/dist/index.cjs
CHANGED
|
@@ -6149,6 +6149,10 @@ function teeRoleOf(row) {
|
|
|
6149
6149
|
function pickExecutingRelay(relays) {
|
|
6150
6150
|
return relays.find((r) => r.canExecute && r.relayUrl !== null && r.executorAccount !== null) ?? null;
|
|
6151
6151
|
}
|
|
6152
|
+
var ACCOUNT_HEX = /^[0-9a-f]{64}$/;
|
|
6153
|
+
function accountHexOrNull(value) {
|
|
6154
|
+
return typeof value === "string" && ACCOUNT_HEX.test(value) ? value : null;
|
|
6155
|
+
}
|
|
6152
6156
|
var AccountHaRefusedError = class extends HTTPError {
|
|
6153
6157
|
constructor(code, status, statusText, url, headers, bodyText) {
|
|
6154
6158
|
super(status, statusText, url, headers, bodyText);
|
|
@@ -6539,7 +6543,9 @@ var CloudClient = class {
|
|
|
6539
6543
|
return (body.relays ?? []).map((row) => ({
|
|
6540
6544
|
peerId: String(row.peer_id ?? ""),
|
|
6541
6545
|
relayUrl: row.relay_url ?? null,
|
|
6542
|
-
fresh: row.fresh === true
|
|
6546
|
+
fresh: row.fresh === true,
|
|
6547
|
+
executorAccount: accountHexOrNull(row.executor_account),
|
|
6548
|
+
assigned: row.assigned === true
|
|
6543
6549
|
}));
|
|
6544
6550
|
}
|
|
6545
6551
|
/**
|
|
@@ -11007,7 +11013,7 @@ function bytes32(value, label2) {
|
|
|
11007
11013
|
}
|
|
11008
11014
|
|
|
11009
11015
|
// src/namespace-op/namespace-op.ts
|
|
11010
|
-
var SIGNED_NAMESPACE_OP_SCHEMA_VERSION =
|
|
11016
|
+
var SIGNED_NAMESPACE_OP_SCHEMA_VERSION = 22;
|
|
11011
11017
|
var NAMESPACE_SIGN_DOMAIN = new TextEncoder().encode("calimero.namespace.v1");
|
|
11012
11018
|
var NAMESPACE_OP_ROOT = 0;
|
|
11013
11019
|
var ROOT_OP2 = {
|