@openframe-org/criteria-set-protocol 2.0.3 → 2.0.4

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,6 +1,4 @@
1
- /// <reference types="node" />
2
1
  import { z } from "zod";
3
- import { Stream } from "stream";
4
2
  export declare const criteriaSetsAndVersionsSchema: z.ZodRecord<z.ZodString, z.ZodArray<z.ZodObject<{
5
3
  id: z.ZodString;
6
4
  version: z.ZodString;
@@ -50,13 +48,13 @@ export declare const criteriaSetsAndVersionsSchema: z.ZodRecord<z.ZodString, z.Z
50
48
  export declare const streamMatrixResponseSchema: z.ZodObject<{
51
49
  filename: z.ZodString;
52
50
  contentType: z.ZodString;
53
- stream: z.ZodType<Stream, z.ZodTypeDef, Stream>;
51
+ stream: z.ZodAny;
54
52
  }, "strip", z.ZodTypeAny, {
55
53
  filename: string;
56
- stream: Stream;
57
54
  contentType: string;
55
+ stream?: any;
58
56
  }, {
59
57
  filename: string;
60
- stream: Stream;
61
58
  contentType: string;
59
+ stream?: any;
62
60
  }>;
@@ -3,10 +3,9 @@ Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.streamMatrixResponseSchema = exports.criteriaSetsAndVersionsSchema = void 0;
4
4
  const zod_1 = require("zod");
5
5
  const metadata_1 = require("./metadata");
6
- const stream_1 = require("stream");
7
6
  exports.criteriaSetsAndVersionsSchema = zod_1.z.record(zod_1.z.string(), zod_1.z.array(metadata_1.metadataSchema));
8
7
  exports.streamMatrixResponseSchema = zod_1.z.object({
9
8
  filename: zod_1.z.string(),
10
9
  contentType: zod_1.z.string(),
11
- stream: zod_1.z.instanceof(stream_1.Stream),
10
+ stream: zod_1.z.any(),
12
11
  });
@@ -1,11 +1,15 @@
1
+ /// <reference types="node" />
1
2
  import { CriteriaTree, DataMap, Metadata } from "./criteria";
2
3
  import { matrixRequestBodySchema, streamMatrixResponseSchema, treeAndDataRequestBodySchema } from "../schemas";
3
4
  import { z } from "zod";
5
+ import { Stream } from "stream";
4
6
  export type MetadataResponse = Metadata;
5
7
  export type CriteriaTreeResponse = CriteriaTree;
6
8
  export type DataMapResponse = DataMap;
7
9
  export type StringParam<ParamName extends string> = Record<ParamName, string>;
8
10
  export type TreeAndDataRequestBody = z.infer<typeof treeAndDataRequestBodySchema>;
9
11
  export type MatrixRequestBody = z.infer<typeof matrixRequestBodySchema>;
10
- export type StreamMatrixResponse = z.infer<typeof streamMatrixResponseSchema>;
12
+ export type StreamMatrixResponse = z.infer<typeof streamMatrixResponseSchema> & {
13
+ stream: Stream;
14
+ };
11
15
  export type ParameterCombination = Record<string, any>;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@openframe-org/criteria-set-protocol",
3
- "version": "2.0.3",
3
+ "version": "2.0.4",
4
4
  "description": "A protocol and tools for defining and working with criteria sets",
5
5
  "private": false,
6
6
  "author": "Andrés Angulo <aa@openframe.org>",