@colyseus/schema 3.0.68 → 3.0.69
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/build/cjs/index.js.map +1 -1
- package/build/esm/index.mjs.map +1 -1
- package/lib/index.d.ts +1 -2
- package/lib/index.js +1 -0
- package/lib/index.js.map +1 -1
- package/package.json +1 -1
- package/src/index.ts +18 -4
package/lib/index.d.ts
CHANGED
|
@@ -17,9 +17,8 @@ export { encode } from "./encoding/encode";
|
|
|
17
17
|
export { decode, type Iterator } from "./encoding/decode";
|
|
18
18
|
export { Reflection, ReflectionType, ReflectionField, } from "./Reflection";
|
|
19
19
|
export { Metadata } from "./Metadata";
|
|
20
|
-
export { type, deprecated, defineTypes, view, schema, entity, type SchemaWithExtends, type SchemaType } from "./annotations";
|
|
20
|
+
export { type, deprecated, defineTypes, view, schema, entity, type DefinitionType, type PrimitiveType, type Definition, type SchemaWithExtendsConstructor, type SchemaWithExtends, type SchemaType, } from "./annotations";
|
|
21
21
|
export { TypeContext } from "./types/TypeContext";
|
|
22
|
-
export type { DefinitionType, PrimitiveType, Definition, } from "./annotations";
|
|
23
22
|
export type { InferValueType, InferSchemaInstanceType, AssignableProps } from "./types/HelperTypes";
|
|
24
23
|
export { getDecoderStateCallbacks, CallbackProxy, SchemaCallback, CollectionCallback, SchemaCallbackProxy } from "./decoder/strategy/StateCallbacks";
|
|
25
24
|
export { getRawChangesCallback } from "./decoder/strategy/RawChanges";
|
package/lib/index.js
CHANGED
|
@@ -43,6 +43,7 @@ Object.defineProperty(exports, "ReflectionField", { enumerable: true, get: funct
|
|
|
43
43
|
// Annotations, Metadata and TypeContext
|
|
44
44
|
var Metadata_1 = require("./Metadata");
|
|
45
45
|
Object.defineProperty(exports, "Metadata", { enumerable: true, get: function () { return Metadata_1.Metadata; } });
|
|
46
|
+
// Schema definition types
|
|
46
47
|
var annotations_1 = require("./annotations");
|
|
47
48
|
Object.defineProperty(exports, "type", { enumerable: true, get: function () { return annotations_1.type; } });
|
|
48
49
|
Object.defineProperty(exports, "deprecated", { enumerable: true, get: function () { return annotations_1.deprecated; } });
|
package/lib/index.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":";;;AAAA,mCAAkC;AAAzB,gGAAA,MAAM,OAAA;AAIf,wDAAoD;AAC3C,0FADA,qBAAS,OACA;AAElB,4DAAyD;AAChD,4FADA,yBAAW,OACA;AAEpB,sEAAmE;AAC1D,iGADA,mCAAgB,OACA;AAEzB,wDAAqD;AAC5C,0FADA,qBAAS,OACA;AAElB,+CAAmE;AAC1D,6FADA,uBAAY,OACA;AAAE,kGADA,4BAAiB,OACA;AAExC,IAAA,uBAAY,EAAC,KAAK,EAAE,EAAE,WAAW,EAAE,qBAAS,EAAE,CAAC,CAAC;AAChD,IAAA,uBAAY,EAAC,OAAO,EAAE,EAAE,WAAW,EAAE,yBAAW,EAAE,CAAC,CAAC;AACpD,IAAA,uBAAY,EAAC,KAAK,EAAE,EAAE,WAAW,EAAE,qBAAS,EAAE,CAAC,CAAC;AAChD,IAAA,uBAAY,EAAC,YAAY,EAAE,EAAE,WAAW,EAAE,mCAAgB,GAAG,CAAC,CAAC;AAE/D,QAAQ;AACR,iCAAsC;AAA7B,oGAAA,WAAW,OAAA;AAEpB,oBAAoB;AACpB,2CAAyH;AAAhH,iGAAA,MAAM,OAAA;AAAE,mGAAA,QAAQ,OAAA;AAAE,mGAAA,QAAQ,OAAA;AAAE,kGAAA,OAAO,OAAA;AAAE,sGAAA,WAAW,OAAA;AAAE,yGAAA,cAAc,OAAA;AAAE,mGAAA,QAAQ,OAAA;AAAE,qGAAA,UAAU,OAAA;AAC/F,4CAA2C;AAAlC,gGAAA,MAAM,OAAA;AACf,4CAA0D;AAAjD,gGAAA,MAAM,OAAA;AAEf,aAAa;AACb,2CAIsB;AAHlB,wGAAA,UAAU,OAAA;AACV,4GAAA,cAAc,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CAAwC;AACxC,uCAAsC;AAA7B,oGAAA,QAAQ,OAAA;AAEjB,0BAA0B;AAC1B,6CAcuB;AAbnB,mGAAA,IAAI,OAAA;AACJ,yGAAA,UAAU,OAAA;AACV,0GAAA,WAAW,OAAA;AACX,mGAAA,IAAI,OAAA;AACJ,qGAAA,MAAM,OAAA;AACN,qGAAA,MAAM,OAAA;AAUV,mDAAkD;AAAzC,0GAAA,WAAW,OAAA;AAKpB,oEAAqJ;AAA5I,0HAAA,wBAAwB,OAAA;AACjC,4DAAsE;AAA7D,mHAAA,qBAAqB,OAAA;AAE9B,6CAA4C;AAAnC,kGAAA,OAAO,OAAA;AAChB,6DAAwG;AAA/F,wHAAA,qBAAqB,OAAA;AAAE,8GAAA,WAAW,OAAA;AAAE,0HAAA,uBAAuB,OAAA;AACpE,mDAAgG;AAAvF,wGAAA,UAAU,OAAA;AACnB,iDAAgD;AAAvC,sGAAA,SAAS,OAAA;AAElB,6CAA4C;AAAnC,kGAAA,OAAO,OAAA;AAChB,6DAA2F;AAAlF,wHAAA,qBAAqB,OAAA;AAAE,0HAAA,uBAAuB,OAAA;AAEvD,wCAA4C;AAAnC,iGAAA,SAAS,OAAA","sourcesContent":["export { Schema } from \"./Schema\";\nexport type { DataChange } from \"./decoder/DecodeOperation\";\nexport type { ToJSON } from \"./types/HelperTypes\";\n\nimport { MapSchema } from \"./types/custom/MapSchema\"\nexport { MapSchema };\n\nimport { ArraySchema } from \"./types/custom/ArraySchema\";\nexport { ArraySchema };\n\nimport { CollectionSchema } from \"./types/custom/CollectionSchema\";\nexport { CollectionSchema };\n\nimport { SetSchema } from \"./types/custom/SetSchema\";\nexport { SetSchema };\n\nimport { registerType, defineCustomTypes } from \"./types/registry\";\nexport { registerType, defineCustomTypes };\n\nregisterType(\"map\", { constructor: MapSchema });\nregisterType(\"array\", { constructor: ArraySchema });\nregisterType(\"set\", { constructor: SetSchema });\nregisterType(\"collection\", { constructor: CollectionSchema, });\n\n// Utils\nexport { dumpChanges } from \"./utils\";\n\n// Encoder / Decoder\nexport { $track, $encoder, $decoder, $filter, $getByIndex, $deleteByIndex, $changes, $childType } from \"./types/symbols\";\nexport { encode } from \"./encoding/encode\";\nexport { decode, type Iterator } from \"./encoding/decode\";\n\n// Reflection\nexport {\n Reflection,\n ReflectionType,\n ReflectionField,\n} from \"./Reflection\";\n\n// Annotations, Metadata and TypeContext\nexport { Metadata } from \"./Metadata\";\n\n// Schema definition types\nexport {\n type,\n deprecated,\n defineTypes,\n view,\n schema,\n entity,\n type DefinitionType,\n type PrimitiveType,\n type Definition,\n // Raw schema() return types\n type SchemaWithExtendsConstructor,\n type SchemaWithExtends,\n type SchemaType,\n} from \"./annotations\";\n\nexport { TypeContext } from \"./types/TypeContext\";\n\n// Helper types for type inference\nexport type { InferValueType, InferSchemaInstanceType, AssignableProps } from \"./types/HelperTypes\";\n\nexport { getDecoderStateCallbacks, CallbackProxy, SchemaCallback, CollectionCallback, SchemaCallbackProxy } from \"./decoder/strategy/StateCallbacks\";\nexport { getRawChangesCallback } from \"./decoder/strategy/RawChanges\";\n\nexport { Encoder } from \"./encoder/Encoder\";\nexport { encodeSchemaOperation, encodeArray, encodeKeyValueOperation } from \"./encoder/EncodeOperation\";\nexport { ChangeTree, Ref, IRef, type ChangeSetName, type ChangeSet} from \"./encoder/ChangeTree\";\nexport { StateView } from \"./encoder/StateView\";\n\nexport { Decoder } from \"./decoder/Decoder\";\nexport { decodeSchemaOperation, decodeKeyValueOperation } from \"./decoder/DecodeOperation\";\n\nexport { OPERATION } from \"./encoding/spec\";"]}
|
package/package.json
CHANGED
package/src/index.ts
CHANGED
|
@@ -39,11 +39,25 @@ export {
|
|
|
39
39
|
|
|
40
40
|
// Annotations, Metadata and TypeContext
|
|
41
41
|
export { Metadata } from "./Metadata";
|
|
42
|
-
export { type, deprecated, defineTypes, view, schema, entity, type SchemaWithExtends, type SchemaType } from "./annotations";
|
|
43
|
-
export { TypeContext } from "./types/TypeContext";
|
|
44
42
|
|
|
45
|
-
//
|
|
46
|
-
export
|
|
43
|
+
// Schema definition types
|
|
44
|
+
export {
|
|
45
|
+
type,
|
|
46
|
+
deprecated,
|
|
47
|
+
defineTypes,
|
|
48
|
+
view,
|
|
49
|
+
schema,
|
|
50
|
+
entity,
|
|
51
|
+
type DefinitionType,
|
|
52
|
+
type PrimitiveType,
|
|
53
|
+
type Definition,
|
|
54
|
+
// Raw schema() return types
|
|
55
|
+
type SchemaWithExtendsConstructor,
|
|
56
|
+
type SchemaWithExtends,
|
|
57
|
+
type SchemaType,
|
|
58
|
+
} from "./annotations";
|
|
59
|
+
|
|
60
|
+
export { TypeContext } from "./types/TypeContext";
|
|
47
61
|
|
|
48
62
|
// Helper types for type inference
|
|
49
63
|
export type { InferValueType, InferSchemaInstanceType, AssignableProps } from "./types/HelperTypes";
|