@spine-event-engine/core 2.0.0-snapshot.25 → 2.0.0-snapshot.26
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 +8 -1
- package/REFERENCE.md +12 -5
- package/dist/index.d.ts +24 -3
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +29 -7
- package/dist/index.js.map +1 -1
- package/dist/spi/reader-forwarding.d.ts +87 -0
- package/dist/spi/reader-forwarding.d.ts.map +1 -0
- package/dist/spi/reader-forwarding.js +162 -0
- package/dist/spi/reader-forwarding.js.map +1 -0
- package/dist/spi/trusted-reader.d.ts +86 -0
- package/dist/spi/trusted-reader.d.ts.map +1 -0
- package/dist/spi/trusted-reader.js +145 -0
- package/dist/spi/trusted-reader.js.map +1 -0
- package/dist/tsconfig.tsbuildinfo +1 -1
- package/dist/validation/registry-validation.d.ts +141 -0
- package/dist/validation/registry-validation.d.ts.map +1 -0
- package/dist/validation/registry-validation.js +342 -0
- package/dist/validation/registry-validation.js.map +1 -0
- package/package.json +10 -2
|
@@ -0,0 +1,342 @@
|
|
|
1
|
+
/*
|
|
2
|
+
* Copyright 2026, CodeMatters. All rights reserved.
|
|
3
|
+
*
|
|
4
|
+
* Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except
|
|
5
|
+
* in compliance with the License. You may obtain a copy of the License at
|
|
6
|
+
*
|
|
7
|
+
* https://www.apache.org/licenses/LICENSE-2.0
|
|
8
|
+
*
|
|
9
|
+
* Unless required by applicable law or agreed to in writing, software distributed under the License
|
|
10
|
+
* is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express
|
|
11
|
+
* or implied. See the License for the specific language governing permissions and limitations under
|
|
12
|
+
* the License.
|
|
13
|
+
*/
|
|
14
|
+
import { create, createRegistry, equals, fromBinary, getOption, ScalarType, } from "@bufbuild/protobuf";
|
|
15
|
+
import { AnySchema } from "@bufbuild/protobuf/wkt";
|
|
16
|
+
import { validate as validateWithSpine } from "@spine-event-engine/validation";
|
|
17
|
+
import { ConstraintViolationSchema, FieldPathSchema, TemplateStringSchema, } from "@spine-event-engine/proto";
|
|
18
|
+
import { required, validate } from "@spine-event-engine/proto/generated/spine/options_pb.js";
|
|
19
|
+
/**
|
|
20
|
+
* Supplements the pinned validator at annotated application `Any` and required collection edges.
|
|
21
|
+
*/
|
|
22
|
+
export const RegistryValidation = {
|
|
23
|
+
/**
|
|
24
|
+
* Finds violations the pinned validator cannot see through its descriptor dependency registry.
|
|
25
|
+
* @param schema The root message schema.
|
|
26
|
+
* @param message The message to inspect.
|
|
27
|
+
* @param registry Application types available at packed fields.
|
|
28
|
+
* @returns Supplemental constraint violations.
|
|
29
|
+
*/
|
|
30
|
+
collect(schema, message, registry) {
|
|
31
|
+
const covered = RegistryValidation.dependencies(schema);
|
|
32
|
+
const violations = [];
|
|
33
|
+
RegistryValidation.scan(schema, message, schema.typeName, [], covered, registry, violations);
|
|
34
|
+
return violations;
|
|
35
|
+
},
|
|
36
|
+
/**
|
|
37
|
+
* Builds the descriptor closure used by the pinned validator for one root.
|
|
38
|
+
* @param schema Descriptor whose file starts the closure.
|
|
39
|
+
* @returns Descriptors visible to upstream validation.
|
|
40
|
+
*/
|
|
41
|
+
dependencies(schema) {
|
|
42
|
+
const files = new Map();
|
|
43
|
+
const pending = [schema.file];
|
|
44
|
+
while (pending.length > 0) {
|
|
45
|
+
const file = pending.pop();
|
|
46
|
+
if (file === undefined || files.has(file.name))
|
|
47
|
+
continue;
|
|
48
|
+
files.set(file.name, file);
|
|
49
|
+
pending.push(...file.dependencies);
|
|
50
|
+
}
|
|
51
|
+
return createRegistry(...files.values());
|
|
52
|
+
},
|
|
53
|
+
/**
|
|
54
|
+
* Exposes selected oneof members by local field name to the pinned validator.
|
|
55
|
+
*
|
|
56
|
+
* @param schema Descriptor of the generated message.
|
|
57
|
+
* @param message Generated message with Protobuf-ES oneof cases.
|
|
58
|
+
* @returns A descriptor-aware view for this validation call.
|
|
59
|
+
*/
|
|
60
|
+
view(schema, message) {
|
|
61
|
+
return new Proxy(RegistryValidation.target(schema, message), {
|
|
62
|
+
/**
|
|
63
|
+
* Resolves oneof or nested fields through the descriptor-aware validation view.
|
|
64
|
+
*/
|
|
65
|
+
get(_target, property) {
|
|
66
|
+
const field = schema.fields.find((candidate) => candidate.localName === property);
|
|
67
|
+
if (field === undefined)
|
|
68
|
+
return Reflect.get(message, property);
|
|
69
|
+
const value = RegistryValidation.value(message, field);
|
|
70
|
+
if (!getOption(field, validate))
|
|
71
|
+
return value;
|
|
72
|
+
const nested = RegistryValidation.messageSchema(field);
|
|
73
|
+
if (nested === undefined)
|
|
74
|
+
return value;
|
|
75
|
+
/**
|
|
76
|
+
* Wraps a nested message for recursive validation while preserving absence.
|
|
77
|
+
*/
|
|
78
|
+
const wrap = (entry) => {
|
|
79
|
+
if (entry === undefined || entry === null)
|
|
80
|
+
return entry;
|
|
81
|
+
return nested.typeName === AnySchema.typeName
|
|
82
|
+
? RegistryValidation.opaque(entry)
|
|
83
|
+
: RegistryValidation.view(nested, entry);
|
|
84
|
+
};
|
|
85
|
+
if (field.fieldKind === "list" && Array.isArray(value))
|
|
86
|
+
return value.map((entry) => wrap(entry));
|
|
87
|
+
if (field.fieldKind === "map" && value && typeof value === "object")
|
|
88
|
+
return Object.fromEntries(Object.entries(value).map(([key, entry]) => [key, wrap(entry)]));
|
|
89
|
+
return value && typeof value === "object" ? wrap(value) : value;
|
|
90
|
+
},
|
|
91
|
+
});
|
|
92
|
+
},
|
|
93
|
+
/**
|
|
94
|
+
* Returns a validation view that hides packed payload types without changing presence.
|
|
95
|
+
*
|
|
96
|
+
* @param packed Original packed value.
|
|
97
|
+
* @returns A view whose type URL prevents upstream unpacking.
|
|
98
|
+
*/
|
|
99
|
+
opaque(packed) {
|
|
100
|
+
return new Proxy(create(AnySchema, { typeUrl: packed.typeUrl, value: packed.value }), {
|
|
101
|
+
/**
|
|
102
|
+
* Hides a packed type URL from the upstream validator while retaining its value.
|
|
103
|
+
*/
|
|
104
|
+
get(_target, property) {
|
|
105
|
+
return property === "typeUrl" && packed.typeUrl
|
|
106
|
+
? "type.spine.io/!validation-opaque"
|
|
107
|
+
: Reflect.get(packed, property);
|
|
108
|
+
},
|
|
109
|
+
});
|
|
110
|
+
},
|
|
111
|
+
/**
|
|
112
|
+
* Copies descriptor-named fields without reflecting source property descriptors.
|
|
113
|
+
* @param schema Descriptor governing the validation view.
|
|
114
|
+
* @param message Input whose field values must remain visible to Buf presence checks.
|
|
115
|
+
* @returns A writable target with the input's actual field presence and oneof cases.
|
|
116
|
+
*/
|
|
117
|
+
target(schema, message) {
|
|
118
|
+
const target = create(schema);
|
|
119
|
+
const source = message;
|
|
120
|
+
for (const field of schema.fields) {
|
|
121
|
+
if (field.oneof) {
|
|
122
|
+
target[field.oneof.localName] = source[field.oneof.localName];
|
|
123
|
+
}
|
|
124
|
+
else if (source[field.localName] !== undefined) {
|
|
125
|
+
target[field.localName] = source[field.localName];
|
|
126
|
+
}
|
|
127
|
+
}
|
|
128
|
+
return target;
|
|
129
|
+
},
|
|
130
|
+
/**
|
|
131
|
+
* Checks required collections and declared recursive validation edges.
|
|
132
|
+
* @param schema Current message descriptor.
|
|
133
|
+
* @param message Current message.
|
|
134
|
+
* @param root Root type name for violations.
|
|
135
|
+
* @param path Path to the current message.
|
|
136
|
+
* @param covered Descriptors already validated upstream.
|
|
137
|
+
* @param registry Application type lookup.
|
|
138
|
+
* @param violations Accumulated violations.
|
|
139
|
+
*/
|
|
140
|
+
scan(schema, message, root, path, covered, registry, violations) {
|
|
141
|
+
for (const field of schema.fields) {
|
|
142
|
+
const value = RegistryValidation.value(message, field);
|
|
143
|
+
if (getOption(field, required))
|
|
144
|
+
RegistryValidation.requiredMembers(field, value, root, path, violations);
|
|
145
|
+
if (!getOption(field, validate))
|
|
146
|
+
continue;
|
|
147
|
+
const nested = RegistryValidation.messageSchema(field);
|
|
148
|
+
if (nested === undefined)
|
|
149
|
+
continue;
|
|
150
|
+
RegistryValidation.scanValues(field, nested, value, root, path, covered, registry, violations);
|
|
151
|
+
}
|
|
152
|
+
},
|
|
153
|
+
/**
|
|
154
|
+
* Processes each selected singular, repeated, or map message value.
|
|
155
|
+
* @param field Declared recursive field.
|
|
156
|
+
* @param nested Descriptor of its message values.
|
|
157
|
+
* @param value Field value.
|
|
158
|
+
* @param root Root type name.
|
|
159
|
+
* @param path Path to the parent message.
|
|
160
|
+
* @param covered Descriptors already validated upstream.
|
|
161
|
+
* @param registry Application type lookup.
|
|
162
|
+
* @param violations Accumulated violations.
|
|
163
|
+
*/
|
|
164
|
+
scanValues(field, nested, value, root, path, covered, registry, violations) {
|
|
165
|
+
for (const [key, entry] of RegistryValidation.entries(field, value)) {
|
|
166
|
+
if (entry === null || entry === undefined)
|
|
167
|
+
continue;
|
|
168
|
+
const nextPath = field.fieldKind === "list" || field.fieldKind === "map"
|
|
169
|
+
? [...path, field.name, key]
|
|
170
|
+
: [...path, field.name];
|
|
171
|
+
if (nested.typeName === AnySchema.typeName) {
|
|
172
|
+
RegistryValidation.any(entry, root, nextPath, covered, registry, violations);
|
|
173
|
+
}
|
|
174
|
+
else if (typeof entry === "object") {
|
|
175
|
+
RegistryValidation.scan(nested, entry, root, nextPath, covered, registry, violations);
|
|
176
|
+
}
|
|
177
|
+
}
|
|
178
|
+
},
|
|
179
|
+
/**
|
|
180
|
+
* Resolves known packed messages while preserving unknown-type allowance.
|
|
181
|
+
* @param packed Packed message.
|
|
182
|
+
* @param root Root type name.
|
|
183
|
+
* @param path Path to the packed field.
|
|
184
|
+
* @param covered Descriptors already validated upstream.
|
|
185
|
+
* @param registry Application type lookup.
|
|
186
|
+
* @param violations Accumulated violations.
|
|
187
|
+
*/
|
|
188
|
+
any(packed, root, path, covered, registry, violations) {
|
|
189
|
+
const name = packed.typeUrl.split("/").at(-1);
|
|
190
|
+
const local = name ? covered.getMessage(name) : undefined;
|
|
191
|
+
const schema = registry?.findByTypeUrl(packed.typeUrl)?.schema ?? local;
|
|
192
|
+
if (schema === undefined)
|
|
193
|
+
return;
|
|
194
|
+
const message = RegistryValidation.decode(schema, packed, root, path, violations);
|
|
195
|
+
if (message === undefined)
|
|
196
|
+
return;
|
|
197
|
+
for (const item of validateWithSpine(schema, RegistryValidation.view(schema, message))) {
|
|
198
|
+
violations.push(RegistryValidation.prefixed(item, root, path));
|
|
199
|
+
}
|
|
200
|
+
const nestedCovered = local === undefined ? RegistryValidation.dependencies(schema) : covered;
|
|
201
|
+
RegistryValidation.scan(schema, message, root, path, nestedCovered, registry, violations);
|
|
202
|
+
},
|
|
203
|
+
/**
|
|
204
|
+
* Converts malformed known bytes into a field violation without exposing the bytes.
|
|
205
|
+
* @param schema Known payload descriptor.
|
|
206
|
+
* @param packed Packed message.
|
|
207
|
+
* @param root Root type name.
|
|
208
|
+
* @param path Path to the packed field.
|
|
209
|
+
* @param violations Accumulated violations.
|
|
210
|
+
* @returns Decoded message, if valid.
|
|
211
|
+
*/
|
|
212
|
+
decode(schema, packed, root, path, violations) {
|
|
213
|
+
try {
|
|
214
|
+
return fromBinary(schema, packed.value);
|
|
215
|
+
}
|
|
216
|
+
catch {
|
|
217
|
+
violations.push(create(ConstraintViolationSchema, {
|
|
218
|
+
typeName: root,
|
|
219
|
+
fieldPath: create(FieldPathSchema, { fieldName: path }),
|
|
220
|
+
message: create(TemplateStringSchema, {
|
|
221
|
+
withPlaceholders: "Known Any payload is malformed.",
|
|
222
|
+
}),
|
|
223
|
+
}));
|
|
224
|
+
return undefined;
|
|
225
|
+
}
|
|
226
|
+
},
|
|
227
|
+
/**
|
|
228
|
+
* Adds a root-relative copy of an application payload violation.
|
|
229
|
+
* @param violation Upstream payload violation.
|
|
230
|
+
* @param root Root type name.
|
|
231
|
+
* @param path Path to the packed field.
|
|
232
|
+
* @returns Violation with the root type and full path.
|
|
233
|
+
*/
|
|
234
|
+
prefixed(violation, root, path) {
|
|
235
|
+
return create(ConstraintViolationSchema, {
|
|
236
|
+
typeName: root,
|
|
237
|
+
fieldPath: create(FieldPathSchema, {
|
|
238
|
+
fieldName: [...path, ...(violation.fieldPath?.fieldName ?? [])],
|
|
239
|
+
}),
|
|
240
|
+
message: violation.message === undefined
|
|
241
|
+
? undefined
|
|
242
|
+
: create(TemplateStringSchema, {
|
|
243
|
+
withPlaceholders: violation.message.withPlaceholders,
|
|
244
|
+
placeholderValue: violation.message.placeholderValue,
|
|
245
|
+
}),
|
|
246
|
+
});
|
|
247
|
+
},
|
|
248
|
+
/**
|
|
249
|
+
* Checks each required list item or map value with the declared presence semantics.
|
|
250
|
+
* @param field Required collection field.
|
|
251
|
+
* @param value Collection value.
|
|
252
|
+
* @param root Root type name.
|
|
253
|
+
* @param path Path to the parent message.
|
|
254
|
+
* @param violations Accumulated violations.
|
|
255
|
+
*/
|
|
256
|
+
requiredMembers(field, value, root, path, violations) {
|
|
257
|
+
if (field.fieldKind !== "list" && field.fieldKind !== "map")
|
|
258
|
+
return;
|
|
259
|
+
for (const [key, member] of RegistryValidation.entries(field, value)) {
|
|
260
|
+
if (RegistryValidation.present(field, member))
|
|
261
|
+
continue;
|
|
262
|
+
violations.push(create(ConstraintViolationSchema, {
|
|
263
|
+
typeName: root,
|
|
264
|
+
fieldPath: create(FieldPathSchema, { fieldName: [...path, field.name, key] }),
|
|
265
|
+
message: create(TemplateStringSchema, {
|
|
266
|
+
withPlaceholders: "A required collection member must have a value.",
|
|
267
|
+
}),
|
|
268
|
+
}));
|
|
269
|
+
}
|
|
270
|
+
},
|
|
271
|
+
/**
|
|
272
|
+
* Determines whether a collection member satisfies declared required semantics.
|
|
273
|
+
* @param field Collection descriptor.
|
|
274
|
+
* @param member Member value.
|
|
275
|
+
* @returns Whether the member is present.
|
|
276
|
+
*/
|
|
277
|
+
present(field, member) {
|
|
278
|
+
if (member === null || member === undefined)
|
|
279
|
+
return false;
|
|
280
|
+
const kind = field.fieldKind === "list" ? field.listKind : field.mapKind;
|
|
281
|
+
if (kind === "scalar") {
|
|
282
|
+
const scalar = field.scalar;
|
|
283
|
+
if (scalar === ScalarType.STRING)
|
|
284
|
+
return typeof member === "string" && member.length > 0;
|
|
285
|
+
if (scalar === ScalarType.BYTES)
|
|
286
|
+
return member instanceof Uint8Array && member.length > 0;
|
|
287
|
+
return true;
|
|
288
|
+
}
|
|
289
|
+
if (kind === "enum")
|
|
290
|
+
return typeof member === "number" && member !== 0;
|
|
291
|
+
const schema = RegistryValidation.messageSchema(field);
|
|
292
|
+
if (schema && typeof member === "object") {
|
|
293
|
+
return !equals(schema, member, create(schema));
|
|
294
|
+
}
|
|
295
|
+
return false;
|
|
296
|
+
},
|
|
297
|
+
/**
|
|
298
|
+
* Lists field values, including missing list or map members for required checks.
|
|
299
|
+
* @param field Field descriptor.
|
|
300
|
+
* @param value Field value.
|
|
301
|
+
* @returns Entries with stable location segments.
|
|
302
|
+
*/
|
|
303
|
+
entries(field, value) {
|
|
304
|
+
if (field.fieldKind === "list")
|
|
305
|
+
return Array.isArray(value)
|
|
306
|
+
? Array.from(value, (entry, index) => [String(index), entry])
|
|
307
|
+
: [];
|
|
308
|
+
if (field.fieldKind === "map")
|
|
309
|
+
return value && typeof value === "object" ? Object.entries(value) : [];
|
|
310
|
+
return value === undefined || value === null ? [] : [["", value]];
|
|
311
|
+
},
|
|
312
|
+
/**
|
|
313
|
+
* Returns the message schema on a declared recursive edge.
|
|
314
|
+
* @param field Field descriptor.
|
|
315
|
+
* @returns Message descriptor, if present.
|
|
316
|
+
*/
|
|
317
|
+
messageSchema(field) {
|
|
318
|
+
if (field.fieldKind === "message")
|
|
319
|
+
return field.message;
|
|
320
|
+
if (field.fieldKind === "list" && field.listKind === "message")
|
|
321
|
+
return field.message;
|
|
322
|
+
if (field.fieldKind === "map" && field.mapKind === "message")
|
|
323
|
+
return field.message;
|
|
324
|
+
return undefined;
|
|
325
|
+
},
|
|
326
|
+
/**
|
|
327
|
+
* Reads the selected generated field, including a oneof member.
|
|
328
|
+
* @param message Generated message.
|
|
329
|
+
* @param field Field descriptor.
|
|
330
|
+
* @returns Selected value.
|
|
331
|
+
*/
|
|
332
|
+
value(message, field) {
|
|
333
|
+
if (field.oneof === undefined)
|
|
334
|
+
return message[field.localName];
|
|
335
|
+
const choice = message[field.oneof.localName];
|
|
336
|
+
if (!choice || typeof choice !== "object")
|
|
337
|
+
return undefined;
|
|
338
|
+
const selected = choice;
|
|
339
|
+
return selected.case === field.localName ? selected.value : undefined;
|
|
340
|
+
},
|
|
341
|
+
};
|
|
342
|
+
//# sourceMappingURL=registry-validation.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"registry-validation.js","sourceRoot":"","sources":["../../src/validation/registry-validation.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;GAYG;AAEH,OAAO,EACL,MAAM,EACN,cAAc,EACd,MAAM,EACN,UAAU,EACV,SAAS,EACT,UAAU,GACX,MAAM,oBAAoB,CAAC;AAE5B,OAAO,EAAE,SAAS,EAAY,MAAM,wBAAwB,CAAC;AAC7D,OAAO,EAAE,QAAQ,IAAI,iBAAiB,EAAE,MAAM,gCAAgC,CAAC;AAC/E,OAAO,EACL,yBAAyB,EACzB,eAAe,EACf,oBAAoB,GACrB,MAAM,2BAA2B,CAAC;AACnC,OAAO,EAAE,QAAQ,EAAE,QAAQ,EAAE,MAAM,yDAAyD,CAAC;AAS7F;;GAEG;AACH,MAAM,CAAC,MAAM,kBAAkB,GAAG;IAChC;;;;;;OAMG;IACH,OAAO,CACL,MAAqB,EACrB,OAAgB,EAChB,QAA6B;QAE7B,MAAM,OAAO,GAAG,kBAAkB,CAAC,YAAY,CAAC,MAAM,CAAC,CAAC;QACxD,MAAM,UAAU,GAA0B,EAAE,CAAC;QAC7C,kBAAkB,CAAC,IAAI,CAAC,MAAM,EAAE,OAAO,EAAE,MAAM,CAAC,QAAQ,EAAE,EAAE,EAAE,OAAO,EAAE,QAAQ,EAAE,UAAU,CAAC,CAAC;QAC7F,OAAO,UAAU,CAAC;IACpB,CAAC;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AAK,SAAS;YAAE,OAAO,KAAK,CAAC,OAAO,CAAC;QACrF,IAAI,KAAK,CAAC,SAAS,KAAK,KAAK,IAAI,KAAK,CAAC,OAAO,KAAK,SAAS;YAAE,OAAO,KAAK,CAAC,OAAO,CAAC;QACnF,OAAO,SAAS,CAAC;IACnB,CAAC;IAED;;;;;OAKG;IACH,KAAK,CAAC,OAAgB,EAAE,KAAgB;QACtC,IAAI,KAAK,CAAC,KAAK,KAAK,SAAS;YAAE,OAAQ,OAAmC,CAAC,KAAK,CAAC,SAAS,CAAC,CAAC;QAC5F,MAAM,MAAM,GAAI,OAAmC,CAAC,KAAK,CAAC,KAAK,CAAC,SAAS,CAAC,CAAC;QAC3E,IAAI,CAAC,MAAM,IAAI,OAAO,MAAM,KAAK,QAAQ;YAAE,OAAO,SAAS,CAAC;QAC5D,MAAM,QAAQ,GAAG,MAA4C,CAAC;QAC9D,OAAO,QAAQ,CAAC,IAAI,KAAK,KAAK,CAAC,SAAS,CAAC,CAAC,CAAC,QAAQ,CAAC,KAAK,CAAC,CAAC,CAAC,SAAS,CAAC;IACxE,CAAC;CACF,CAAC"}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@spine-event-engine/core",
|
|
3
|
-
"version": "2.0.0-snapshot.
|
|
3
|
+
"version": "2.0.0-snapshot.26",
|
|
4
4
|
"license": "Apache-2.0",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"repository": {
|
|
@@ -33,6 +33,14 @@
|
|
|
33
33
|
"./spi/entity-query-plan": {
|
|
34
34
|
"types": "./dist/spi/entity-query-plan.d.ts",
|
|
35
35
|
"default": "./dist/spi/entity-query-plan.js"
|
|
36
|
+
},
|
|
37
|
+
"./spi/trusted-reader": {
|
|
38
|
+
"types": "./dist/spi/trusted-reader.d.ts",
|
|
39
|
+
"default": "./dist/spi/trusted-reader.js"
|
|
40
|
+
},
|
|
41
|
+
"./spi/reader-forwarding": {
|
|
42
|
+
"types": "./dist/spi/reader-forwarding.d.ts",
|
|
43
|
+
"default": "./dist/spi/reader-forwarding.js"
|
|
36
44
|
}
|
|
37
45
|
},
|
|
38
46
|
"files": [
|
|
@@ -43,6 +51,6 @@
|
|
|
43
51
|
"dependencies": {
|
|
44
52
|
"@bufbuild/protobuf": "2.12.1",
|
|
45
53
|
"@spine-event-engine/validation": "2.0.0-snapshot.7",
|
|
46
|
-
"@spine-event-engine/proto": "2.0.0-snapshot.
|
|
54
|
+
"@spine-event-engine/proto": "2.0.0-snapshot.26"
|
|
47
55
|
}
|
|
48
56
|
}
|