@mengine/medeo-client 2.1.1-dsl.8 → 3.0.0

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/dist/testing.d.ts CHANGED
@@ -1,5 +1,4 @@
1
- import { i as VideoDraft } from "./video-draft-types-Bq15tPBP.js";
2
- import { b as MedeoDsl } from "./index-DHcMMn2M.js";
1
+ import { M as MedeoDsl, d as VideoDraft } from "./index-DuM7I4Ku.js";
3
2
  import { LoroDoc } from "loro-crdt";
4
3
 
5
4
  //#region src/testing/in-memory-mengine-server.d.ts
package/dist/testing.js CHANGED
@@ -1,6 +1,5 @@
1
1
  import { n as bytesToBase64, t as base64ToBytes } from "./base64-D-jd-dr5.js";
2
- import { a as documentFormat, i as assertDslDocument } from "./video-draft-types-Ce8NDenQ.js";
3
- import { a as DslEditor, i as createInitialMedeoDsl, n as toVideoDraft, o as MedeoDsl } from "./dsl-DbYqFFOb.js";
2
+ import { a as DslEditor, i as createInitialMedeoDsl, l as assertDslDocument, n as toVideoDraft, s as MedeoDsl, u as documentFormat } from "./dsl-Cpk8WxcZ.js";
4
3
  import { t as classifyUpdate } from "./loro-relay-doc-Bi6JKqtQ.js";
5
4
  import { LoroDoc, VersionVector, encodeFrontiers } from "loro-crdt";
6
5
  //#region src/testing/in-memory-mengine-server.ts
@@ -167,10 +166,11 @@ var InMemoryMengineServer = class {
167
166
  try {
168
167
  probe.import(this.doc.export({ mode: "snapshot" }));
169
168
  probe.import(data);
170
- if (documentFormat(probe) === "mixed") return Response.json({
169
+ const format = documentFormat(probe);
170
+ if (format === "legacy" || format === "mixed") return Response.json({
171
171
  kind: "rejected",
172
172
  code: "unsupported_document_format",
173
- message: "Cannot mix legacy and DSL content roots",
173
+ message: "Retired document content roots are not supported",
174
174
  server_version: serverVersion
175
175
  }, { status: 422 });
176
176
  } finally {
@@ -450,7 +450,7 @@ function createTestDsl(options = {}) {
450
450
  durationMs: 1e3,
451
451
  storageKey: "speech.mp3"
452
452
  },
453
- script: { body: "hello" },
453
+ script: { segments: ["hello"] },
454
454
  volume: 1,
455
455
  voice: {
456
456
  system: "voice-library",
@@ -466,10 +466,7 @@ function createTestDsl(options = {}) {
466
466
  clipId: "caption",
467
467
  startMs: 0,
468
468
  durationMs: 1e3,
469
- range: {
470
- start: 0,
471
- end: 5
472
- },
469
+ segment: 0,
473
470
  style: {}
474
471
  }]
475
472
  });
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@mengine/medeo-client",
3
- "version": "2.1.1-dsl.8",
3
+ "version": "3.0.0",
4
4
  "license": "UNLICENSED",
5
5
  "repository": {
6
6
  "type": "git",
@@ -15,9 +15,7 @@
15
15
  "exports": {
16
16
  ".": "./dist/index.js",
17
17
  "./dsl": "./dist/dsl.js",
18
- "./legacy": "./dist/legacy.js",
19
18
  "./relay": "./dist/relay.js",
20
- "./schemas": "./dist/schemas.js",
21
19
  "./testing": "./dist/testing.js",
22
20
  "./package.json": "./package.json"
23
21
  },
@@ -27,28 +25,27 @@
27
25
  },
28
26
  "dependencies": {
29
27
  "@noble/hashes": "^2.4.0",
30
- "immer": "^10.2.0",
31
- "zod": "^4.4.3",
32
- "@mengine/sync": "2.1.1-dsl.8",
33
- "@mengine/utils": "2.1.1-dsl.8",
34
- "@mengine/storage": "2.1.1-dsl.8"
28
+ "@mengine/storage": "3.0.0",
29
+ "@mengine/sync": "3.0.0",
30
+ "@mengine/utils": "3.0.0"
35
31
  },
36
32
  "devDependencies": {
37
33
  "@types/node": "^25.9.1",
38
34
  "@typescript/native-preview": "7.0.0-dev.20260521.1",
39
- "loro-crdt": "^1.16.1",
35
+ "loro-crdt": "^1.16.4",
40
36
  "loro-mirror": "2.3.3",
41
37
  "tsx": "^4.22.3",
42
38
  "typescript": "^6.0.3",
43
39
  "vite-plugin-wasm": "^3.6.0",
44
40
  "vite-plus": "^0.1.23",
45
- "@mengine/idl-codegen": "0.0.0",
46
- "@mengine/medeo-dsl": "0.0.0"
41
+ "@mengine/medeo-dsl": "0.0.0",
42
+ "@mengine/idl-codegen": "0.0.0"
47
43
  },
48
44
  "peerDependencies": {
49
- "loro-crdt": "^1.16.1"
45
+ "loro-crdt": "^1.16.4"
50
46
  },
51
47
  "inlinedDependencies": {
48
+ "immer": "10.2.0",
52
49
  "loro-mirror": "2.3.3"
53
50
  },
54
51
  "scripts": {
@@ -1,179 +0,0 @@
1
- import { R as MedeoDslSnapshot, W as ResourceSystem, et as TrackRole } from "./video-draft-types-Bq15tPBP.js";
2
- import { b as MedeoDsl, h as UploadText, i as AudioScriptView, m as DslEditor, o as VideoDraftProjection } from "./index-DHcMMn2M.js";
3
- import { _ as ManualSyncTransport, a as MengineDocSessionOptions, g as ManualSyncDocOptions, n as DocumentSession, r as DocumentSessionUpdateEvent } from "./index-Dpl4bT94.js";
4
-
5
- //#region src/manual-sync/manual-sync-doc.d.ts
6
- /** Explicit synchronization over the same DSL/editor used by the live Session. */
7
- declare class ManualSyncDoc extends ManualSyncTransport {
8
- readonly dsl: MedeoDsl;
9
- readonly editor: DslEditor;
10
- private constructor();
11
- /** `uploadText` stores raw content the editor writes, such as a PhoneticScript's text, in Memota. */
12
- static open(options: ManualSyncDocOptions & {
13
- uploadText?: UploadText;
14
- }): Promise<ManualSyncDoc>;
15
- snapshot(): {
16
- readonly "timeline-entities": {
17
- readonly [x: string]: {
18
- readonly [x: string]: never;
19
- };
20
- };
21
- readonly "track-entities": {
22
- readonly [x: string]: {
23
- readonly role: TrackRole;
24
- readonly hidden?: boolean | undefined;
25
- };
26
- };
27
- readonly "clip-entities": {
28
- readonly [x: string]: {
29
- readonly seqMarker: {
30
- readonly inMs: number;
31
- readonly outMs: number;
32
- readonly rate?: number | undefined;
33
- readonly fillTimeline?: true | undefined;
34
- };
35
- readonly volume?: number | undefined;
36
- readonly source: string;
37
- readonly anchor?: {
38
- readonly to: string;
39
- readonly offsetMs: number;
40
- readonly fallback_abs_ms: number;
41
- } | undefined;
42
- };
43
- };
44
- readonly "media-entities": {
45
- readonly [x: string]: {
46
- readonly system: ResourceSystem;
47
- readonly key: string;
48
- readonly digest?: string | undefined;
49
- readonly kind: "video";
50
- readonly durationMs: number;
51
- readonly storageKey?: string | undefined;
52
- } | {
53
- readonly system: ResourceSystem;
54
- readonly key: string;
55
- readonly digest?: string | undefined;
56
- readonly kind: "audio" | "voiceover-recording";
57
- readonly durationMs: number;
58
- readonly storageKey: string;
59
- } | {
60
- readonly system: ResourceSystem;
61
- readonly key: string;
62
- readonly digest?: string | undefined;
63
- readonly kind: "image";
64
- readonly storageKey?: string | undefined;
65
- };
66
- };
67
- readonly "audio-script-entities": {
68
- readonly [x: string]: {
69
- readonly body: string;
70
- readonly defaultLanguage?: string | undefined;
71
- };
72
- };
73
- readonly "phonetic-script-entities": {
74
- readonly [x: string]: {
75
- readonly phoneme: {
76
- readonly audioScriptId: string;
77
- readonly phonemeScript?: string | undefined;
78
- };
79
- readonly system?: "memota" | undefined;
80
- readonly key?: string | undefined;
81
- readonly storageKey?: string | undefined;
82
- readonly digest?: string | undefined;
83
- };
84
- };
85
- readonly "caption-entities": {
86
- readonly [x: string]: {
87
- readonly selection?: {
88
- readonly audioScriptId: string;
89
- readonly start: import("loro-crdt").Cursor;
90
- readonly end: import("loro-crdt").Cursor;
91
- } | undefined;
92
- readonly text?: string | undefined;
93
- readonly style?: {
94
- readonly font?: {
95
- readonly system: "font-library";
96
- readonly key: string;
97
- } | undefined;
98
- readonly fontSize?: number | undefined;
99
- readonly fontColor?: string | undefined;
100
- readonly fontWeight?: number | undefined;
101
- readonly entranceAnimation?: string | undefined;
102
- readonly entranceAnimationDurationMs?: number | undefined;
103
- readonly strokeColor?: string | undefined;
104
- readonly strokeWidth?: number | undefined;
105
- readonly positionX?: number | undefined;
106
- readonly positionY?: number | undefined;
107
- } | undefined;
108
- };
109
- };
110
- readonly "voice-entities": {
111
- readonly [x: string]: {
112
- readonly system: "voice-library";
113
- readonly key: string;
114
- readonly name?: string | undefined;
115
- };
116
- };
117
- readonly "voice-timbre-relations": {
118
- readonly [x: string]: {
119
- readonly recordingId: string;
120
- readonly voiceId: string;
121
- };
122
- };
123
- readonly "derived-from-relations": {
124
- readonly [x: string]: {
125
- readonly entityId: string;
126
- readonly sourceId: string;
127
- readonly sourceDigest?: string | undefined;
128
- };
129
- };
130
- readonly 'contain-relations': readonly {
131
- readonly treeId: import("loro-crdt").TreeID;
132
- readonly entityId: string;
133
- readonly children: readonly /*elided*/any[];
134
- }[];
135
- readonly richText: {
136
- readonly [x: string]: {
137
- readonly bodyId: string;
138
- readonly plainText: string;
139
- readonly delta: readonly {
140
- readonly insert: string;
141
- readonly attributes?: {
142
- readonly [x: string]: unknown;
143
- } | undefined;
144
- }[];
145
- };
146
- };
147
- readonly captionText: {
148
- readonly [x: string]: {
149
- readonly text: string;
150
- readonly start: number;
151
- readonly end: number;
152
- readonly bodyId: string;
153
- };
154
- };
155
- readonly diagnostics: readonly {
156
- readonly code: string;
157
- readonly path: string;
158
- readonly message: string;
159
- }[];
160
- };
161
- projectVideoDraft(): VideoDraftProjection;
162
- dispose(): void;
163
- }
164
- //#endregion
165
- //#region src/session/mengine-doc-session.d.ts
166
- type MengineDocSessionUpdateEvent = DocumentSessionUpdateEvent<MedeoDslSnapshot>;
167
- /** Default collaborative session: one DSL handle and one editor over the synchronized LoroDoc. */
168
- declare class MengineDocSession extends DocumentSession<MedeoDslSnapshot, DslEditor, MedeoDsl> {
169
- /** `uploadText` stores raw content the editor writes, such as a PhoneticScript's text, in Memota. */
170
- constructor(options: MengineDocSessionOptions & {
171
- uploadText?: UploadText;
172
- });
173
- get dsl(): MedeoDsl;
174
- projectVideoDraft(): VideoDraftProjection;
175
- /** The document's AudioScripts with what says and shows them; read from the same snapshot as the VideoDraft. */
176
- projectAudioScripts(): AudioScriptView[];
177
- }
178
- //#endregion
179
- export { MengineDocSessionUpdateEvent as n, ManualSyncDoc as r, MengineDocSession as t };