@markless/serializer 0.1.1 → 0.2.1

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,5 +1,6 @@
1
1
  //#region src/protocol.d.ts
2
2
  declare const ASYNC_PROTOCOL_VERSION = 1;
3
+ declare const STORAGE_PROTOCOL_VERSION = 2;
3
4
  type ProtocolSyncPolicyCondition = {
4
5
  readonly type: 'and';
5
6
  readonly conditions: ReadonlyArray<ProtocolSyncPolicyCondition>;
@@ -29,7 +30,7 @@ type ProtocolSyncPolicy = ProtocolSyncPolicyBranch | {
29
30
  readonly branches: ReadonlyArray<ProtocolSyncPolicyBranch>;
30
31
  };
31
32
  type ProtocolStatePayload = {
32
- readonly version: typeof ASYNC_PROTOCOL_VERSION;
33
+ readonly version: typeof ASYNC_PROTOCOL_VERSION | typeof STORAGE_PROTOCOL_VERSION;
33
34
  readonly cells: ReadonlyArray<{
34
35
  readonly graphNodeId: string;
35
36
  readonly name: string;
@@ -85,6 +86,10 @@ type ProtocolStatePayload = {
85
86
  readonly name: string;
86
87
  }>;
87
88
  }>;
89
+ readonly storage?: ReadonlyArray<{
90
+ readonly graphNodeId: string;
91
+ readonly key: string;
92
+ }>;
88
93
  };
89
94
  type ProtocolArmBranchRecord = {
90
95
  readonly id: string;
@@ -120,6 +125,7 @@ type ProtocolArmRecordSet = {
120
125
  };
121
126
  type ProtocolViewPayload = {
122
127
  readonly version: typeof ASYNC_PROTOCOL_VERSION;
128
+ readonly asyncRunners?: Readonly<Record<string, string>>;
123
129
  readonly locators: ReadonlyArray<{
124
130
  readonly hostNodeId: string;
125
131
  readonly strategy: 'dom-order';
@@ -248,4 +254,4 @@ type ProtocolPayloadScripts = {
248
254
  readonly viewScript: string;
249
255
  };
250
256
  //#endregion
251
- export { ASYNC_PROTOCOL_VERSION, ProtocolArmBranchRecord, ProtocolArmRecordSet, ProtocolPayloadScripts, ProtocolStatePayload, ProtocolSyncPolicy, ProtocolSyncPolicyBranch, ProtocolSyncPolicyCondition, ProtocolViewPayload };
257
+ export { ASYNC_PROTOCOL_VERSION, ProtocolArmBranchRecord, ProtocolArmRecordSet, ProtocolPayloadScripts, ProtocolStatePayload, ProtocolSyncPolicy, ProtocolSyncPolicyBranch, ProtocolSyncPolicyCondition, ProtocolViewPayload, STORAGE_PROTOCOL_VERSION };
package/dist/protocol.js CHANGED
@@ -1,4 +1,5 @@
1
1
  //#region src/protocol.ts
2
2
  const ASYNC_PROTOCOL_VERSION = 1;
3
+ const STORAGE_PROTOCOL_VERSION = 2;
3
4
  //#endregion
4
- export { ASYNC_PROTOCOL_VERSION };
5
+ export { ASYNC_PROTOCOL_VERSION, STORAGE_PROTOCOL_VERSION };
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@markless/serializer",
3
- "version": "0.1.1",
3
+ "version": "0.2.1",
4
4
  "description": "Markless serialization tiers and resumability payload protocol.",
5
5
  "license": "MIT",
6
6
  "repository": {
@@ -9,7 +9,8 @@
9
9
  "directory": "packages/serializer"
10
10
  },
11
11
  "publishConfig": {
12
- "access": "public"
12
+ "access": "public",
13
+ "provenance": true
13
14
  },
14
15
  "type": "module",
15
16
  "sideEffects": false,