@openframe-org/criteria-set-protocol 1.5.3 → 1.5.5

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.
@@ -32,6 +32,31 @@ export declare const percentageBasedCertificationDefinitionRulesSchema: z.ZodObj
32
32
  exclusiveMinimum?: number | undefined;
33
33
  exclusiveMaximum?: number | undefined;
34
34
  }>;
35
+ export declare const abstractCertificationDefinitionSchema: z.ZodObject<{
36
+ code: z.ZodString;
37
+ type: z.ZodUnion<[z.ZodLiteral<"number">, z.ZodLiteral<"percentage">]>;
38
+ icon: z.ZodOptional<z.ZodString>;
39
+ name: z.ZodString;
40
+ description: z.ZodOptional<z.ZodString>;
41
+ rules: z.ZodAny;
42
+ rulesText: z.ZodString;
43
+ }, "strip", z.ZodTypeAny, {
44
+ type: "number" | "percentage";
45
+ code: string;
46
+ name: string;
47
+ rulesText: string;
48
+ description?: string | undefined;
49
+ icon?: string | undefined;
50
+ rules?: any;
51
+ }, {
52
+ type: "number" | "percentage";
53
+ code: string;
54
+ name: string;
55
+ rulesText: string;
56
+ description?: string | undefined;
57
+ icon?: string | undefined;
58
+ rules?: any;
59
+ }>;
35
60
  export declare const numberBasedCertificationDefinitionSchema: z.ZodObject<z.objectUtil.extendShape<{
36
61
  code: z.ZodString;
37
62
  type: z.ZodUnion<[z.ZodLiteral<"number">, z.ZodLiteral<"percentage">]>;
@@ -1,6 +1,6 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.certificationDefinitionSchema = exports.percentageBasedCertificationDefinitionSchema = exports.numberBasedCertificationDefinitionSchema = exports.percentageBasedCertificationDefinitionRulesSchema = exports.numberBasedCertificationDefinitionRulesSchema = exports.certificationDefinitionTypeSchema = void 0;
3
+ exports.certificationDefinitionSchema = exports.percentageBasedCertificationDefinitionSchema = exports.numberBasedCertificationDefinitionSchema = exports.abstractCertificationDefinitionSchema = exports.percentageBasedCertificationDefinitionRulesSchema = exports.numberBasedCertificationDefinitionRulesSchema = exports.certificationDefinitionTypeSchema = void 0;
4
4
  const zod_1 = require("zod");
5
5
  exports.certificationDefinitionTypeSchema = zod_1.z.union([zod_1.z.literal('number'), zod_1.z.literal('percentage')]);
6
6
  exports.numberBasedCertificationDefinitionRulesSchema = zod_1.z.object({
@@ -10,7 +10,7 @@ exports.numberBasedCertificationDefinitionRulesSchema = zod_1.z.object({
10
10
  exclusiveMaximum: zod_1.z.number().optional()
11
11
  });
12
12
  exports.percentageBasedCertificationDefinitionRulesSchema = exports.numberBasedCertificationDefinitionRulesSchema;
13
- const abstractCertificationDefinitionSchema = zod_1.z.object({
13
+ exports.abstractCertificationDefinitionSchema = zod_1.z.object({
14
14
  code: zod_1.z.string(),
15
15
  type: exports.certificationDefinitionTypeSchema,
16
16
  icon: zod_1.z.string().optional(),
@@ -19,11 +19,11 @@ const abstractCertificationDefinitionSchema = zod_1.z.object({
19
19
  rules: zod_1.z.any(),
20
20
  rulesText: zod_1.z.string()
21
21
  });
22
- exports.numberBasedCertificationDefinitionSchema = abstractCertificationDefinitionSchema.extend({
22
+ exports.numberBasedCertificationDefinitionSchema = exports.abstractCertificationDefinitionSchema.extend({
23
23
  type: zod_1.z.literal('number'),
24
24
  rules: exports.numberBasedCertificationDefinitionRulesSchema
25
25
  });
26
- exports.percentageBasedCertificationDefinitionSchema = abstractCertificationDefinitionSchema.extend({
26
+ exports.percentageBasedCertificationDefinitionSchema = exports.abstractCertificationDefinitionSchema.extend({
27
27
  type: zod_1.z.literal('percentage'),
28
28
  rules: exports.percentageBasedCertificationDefinitionRulesSchema
29
29
  });
@@ -1,6 +1,6 @@
1
1
  import { z } from 'zod';
2
- export declare const schemaDefinition: z.ZodRecord<z.ZodString, z.ZodAny>;
3
- export declare const schemaDefinitions: z.ZodObject<{
2
+ export declare const schemaDefinitionSchema: z.ZodRecord<z.ZodString, z.ZodAny>;
3
+ export declare const schemaDefinitionsSchema: z.ZodObject<{
4
4
  parameters: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodAny>>;
5
5
  result: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodAny>>;
6
6
  }, "strip", z.ZodTypeAny, {
@@ -1,11 +1,11 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.metadataSchema = exports.schemaDefinitions = exports.schemaDefinition = void 0;
3
+ exports.metadataSchema = exports.schemaDefinitionsSchema = exports.schemaDefinitionSchema = void 0;
4
4
  const zod_1 = require("zod");
5
- exports.schemaDefinition = zod_1.z.record(zod_1.z.string(), zod_1.z.any());
6
- exports.schemaDefinitions = zod_1.z.object({
7
- parameters: exports.schemaDefinition.optional(),
8
- result: exports.schemaDefinition.optional()
5
+ exports.schemaDefinitionSchema = zod_1.z.record(zod_1.z.string(), zod_1.z.any());
6
+ exports.schemaDefinitionsSchema = zod_1.z.object({
7
+ parameters: exports.schemaDefinitionSchema.optional(),
8
+ result: exports.schemaDefinitionSchema.optional()
9
9
  });
10
10
  exports.metadataSchema = zod_1.z.object({
11
11
  id: zod_1.z.string(),
@@ -16,5 +16,5 @@ exports.metadataSchema = zod_1.z.object({
16
16
  documentation: zod_1.z.string().optional(),
17
17
  locales: zod_1.z.array(zod_1.z.string()).optional(),
18
18
  defaultLocale: zod_1.z.string().optional(),
19
- schemas: exports.schemaDefinitions.optional()
19
+ schemas: exports.schemaDefinitionsSchema.optional()
20
20
  });
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@openframe-org/criteria-set-protocol",
3
- "version": "1.5.3",
3
+ "version": "1.5.5",
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>",