@bcts/dcbor 1.0.0-alpha.21 → 1.0.0-alpha.23
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/README.md +1 -1
- package/dist/index.cjs +88 -158
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.cts.map +1 -1
- package/dist/index.d.mts.map +1 -1
- package/dist/index.iife.js +327 -446
- package/dist/index.iife.js.map +1 -1
- package/dist/index.mjs +87 -156
- package/dist/index.mjs.map +1 -1
- package/package.json +9 -9
- package/src/diag.ts +4 -5
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@bcts/dcbor",
|
|
3
|
-
"version": "1.0.0-alpha.
|
|
3
|
+
"version": "1.0.0-alpha.23",
|
|
4
4
|
"type": "module",
|
|
5
5
|
"description": "Blockchain Commons Deterministic CBOR (dCBOR) for TypeScript",
|
|
6
6
|
"license": "BSD-2-Clause-Patent",
|
|
@@ -60,15 +60,15 @@
|
|
|
60
60
|
"@bcts/tsconfig": "^0.1.0",
|
|
61
61
|
"@eslint/js": "^10.0.1",
|
|
62
62
|
"@types/collections": "^5.1.5",
|
|
63
|
-
"@types/node": "^25.
|
|
64
|
-
"@typescript-eslint/eslint-plugin": "^8.
|
|
65
|
-
"@typescript-eslint/parser": "^8.
|
|
66
|
-
"eslint": "^10.
|
|
63
|
+
"@types/node": "^25.6.0",
|
|
64
|
+
"@typescript-eslint/eslint-plugin": "^8.59.0",
|
|
65
|
+
"@typescript-eslint/parser": "^8.59.0",
|
|
66
|
+
"eslint": "^10.2.1",
|
|
67
67
|
"ts-node": "^10.9.2",
|
|
68
|
-
"tsdown": "^0.
|
|
69
|
-
"typedoc": "^0.28.
|
|
70
|
-
"typescript": "^
|
|
71
|
-
"vitest": "^4.
|
|
68
|
+
"tsdown": "^0.21.0",
|
|
69
|
+
"typedoc": "^0.28.19",
|
|
70
|
+
"typescript": "^6.0.3",
|
|
71
|
+
"vitest": "^4.1.5"
|
|
72
72
|
},
|
|
73
73
|
"dependencies": {
|
|
74
74
|
"byte-data": "^19.0.1",
|
package/src/diag.ts
CHANGED
|
@@ -171,15 +171,14 @@ export function diagnosticFlat(input: Cbor | WalkElement): string {
|
|
|
171
171
|
"type" in input &&
|
|
172
172
|
(input.type === "single" || input.type === "keyvalue")
|
|
173
173
|
) {
|
|
174
|
-
|
|
175
|
-
|
|
176
|
-
return diagnosticOpt(element.cbor, { flat: true });
|
|
174
|
+
if (input.type === "single") {
|
|
175
|
+
return diagnosticOpt(input.cbor, { flat: true });
|
|
177
176
|
} else {
|
|
178
|
-
return `${diagnosticOpt(
|
|
177
|
+
return `${diagnosticOpt(input.key, { flat: true })}: ${diagnosticOpt(input.value, { flat: true })}`;
|
|
179
178
|
}
|
|
180
179
|
}
|
|
181
180
|
// Otherwise treat as Cbor
|
|
182
|
-
return diagnosticOpt(input
|
|
181
|
+
return diagnosticOpt(input, { flat: true });
|
|
183
182
|
}
|
|
184
183
|
|
|
185
184
|
/**
|