@remotion/studio-shared 4.0.437 → 4.0.439

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.
@@ -143,15 +143,22 @@ export type DeleteStaticFileResponse = {
143
143
  success: boolean;
144
144
  existed: boolean;
145
145
  };
146
- export type CanUpdateDefaultPropsRequest = {
147
- compositionId: string;
148
- };
149
146
  export type CanUpdateDefaultPropsResponse = {
150
147
  canUpdate: true;
148
+ currentDefaultProps: Record<string, unknown>;
151
149
  } | {
152
150
  canUpdate: false;
153
151
  reason: string;
154
152
  };
153
+ export type SubscribeToDefaultPropsRequest = {
154
+ compositionId: string;
155
+ clientId: string;
156
+ };
157
+ export type SubscribeToDefaultPropsResponse = CanUpdateDefaultPropsResponse;
158
+ export type UnsubscribeFromDefaultPropsRequest = {
159
+ compositionId: string;
160
+ clientId: string;
161
+ };
155
162
  export type CanUpdateSequencePropsRequest = {
156
163
  fileName: string;
157
164
  nodePath: SequenceNodePath;
@@ -184,12 +191,15 @@ export type SaveSequencePropsRequest = {
184
191
  key: string;
185
192
  value: string;
186
193
  defaultValue: string | null;
194
+ observedKeys: string[];
187
195
  };
188
196
  export type SaveSequencePropsResponse = {
189
197
  success: true;
198
+ newStatus: CanUpdateSequencePropsResponse;
190
199
  } | {
191
200
  success: false;
192
201
  reason: string;
202
+ stack: string;
193
203
  };
194
204
  export type UpdateAvailableRequest = {};
195
205
  export type UpdateAvailableResponse = {
@@ -209,6 +219,20 @@ export type InstallPackageRequest = {
209
219
  packageNames: string[];
210
220
  };
211
221
  export type InstallPackageResponse = {};
222
+ export type UndoRequest = {};
223
+ export type UndoResponse = {
224
+ success: true;
225
+ } | {
226
+ success: false;
227
+ reason: string;
228
+ };
229
+ export type RedoRequest = {};
230
+ export type RedoResponse = {
231
+ success: true;
232
+ } | {
233
+ success: false;
234
+ reason: string;
235
+ };
212
236
  export type ApiRoutes = {
213
237
  '/api/cancel': ReqAndRes<CancelRenderRequest, CancelRenderResponse>;
214
238
  '/api/render': ReqAndRes<AddRenderRequest, undefined>;
@@ -218,7 +242,8 @@ export type ApiRoutes = {
218
242
  '/api/open-in-file-explorer': ReqAndRes<OpenInFileExplorerRequest, void>;
219
243
  '/api/update-default-props': ReqAndRes<UpdateDefaultPropsRequest, UpdateDefaultPropsResponse>;
220
244
  '/api/apply-visual-control-change': ReqAndRes<ApplyVisualControlRequest, ApplyVisualControlResponse>;
221
- '/api/can-update-default-props': ReqAndRes<CanUpdateDefaultPropsRequest, CanUpdateDefaultPropsResponse>;
245
+ '/api/subscribe-to-default-props': ReqAndRes<SubscribeToDefaultPropsRequest, SubscribeToDefaultPropsResponse>;
246
+ '/api/unsubscribe-from-default-props': ReqAndRes<UnsubscribeFromDefaultPropsRequest, undefined>;
222
247
  '/api/subscribe-to-sequence-props': ReqAndRes<SubscribeToSequencePropsRequest, SubscribeToSequencePropsResponse>;
223
248
  '/api/unsubscribe-from-sequence-props': ReqAndRes<UnsubscribeFromSequencePropsRequest, undefined>;
224
249
  '/api/save-sequence-props': ReqAndRes<SaveSequencePropsRequest, SaveSequencePropsResponse>;
@@ -228,5 +253,7 @@ export type ApiRoutes = {
228
253
  '/api/delete-static-file': ReqAndRes<DeleteStaticFileRequest, DeleteStaticFileResponse>;
229
254
  '/api/restart-studio': ReqAndRes<RestartStudioRequest, RestartStudioResponse>;
230
255
  '/api/install-package': ReqAndRes<InstallPackageRequest, InstallPackageResponse>;
256
+ '/api/undo': ReqAndRes<UndoRequest, UndoResponse>;
257
+ '/api/redo': ReqAndRes<RedoRequest, RedoResponse>;
231
258
  };
232
259
  export {};
@@ -2,6 +2,7 @@ import type { EnumPath } from './stringify-default-props';
2
2
  export type VisualControlChange = {
3
3
  id: string;
4
4
  newValueSerialized: string;
5
+ newValueIsUndefined: boolean;
5
6
  enumPaths: EnumPath[];
6
7
  };
7
8
  export type ApplyVisualControlCodemod = {
@@ -1,5 +1,5 @@
1
1
  import type { StaticFile } from 'remotion';
2
- import type { CanUpdateSequencePropsResponse, SequenceNodePath } from './api-requests';
2
+ import type { CanUpdateDefaultPropsResponse, CanUpdateSequencePropsResponse, SequenceNodePath } from './api-requests';
3
3
  import type { CompletedClientRender, RenderJob } from './render-job';
4
4
  export type EventSourceEvent = {
5
5
  type: 'new-input-props';
@@ -7,6 +7,8 @@ export type EventSourceEvent = {
7
7
  } | {
8
8
  type: 'init';
9
9
  clientId: string;
10
+ undoFile: string | null;
11
+ redoFile: string | null;
10
12
  } | {
11
13
  type: 'new-env-variables';
12
14
  newEnvVariables: Record<string, string>;
@@ -37,4 +39,19 @@ export type EventSourceEvent = {
37
39
  fileName: string;
38
40
  nodePath: SequenceNodePath;
39
41
  result: CanUpdateSequencePropsResponse;
42
+ } | {
43
+ type: 'default-props-updatable-changed';
44
+ compositionId: string;
45
+ result: CanUpdateDefaultPropsResponse;
46
+ } | {
47
+ type: 'undo-redo-stack-changed';
48
+ undoFile: string | null;
49
+ redoFile: string | null;
50
+ } | {
51
+ type: 'visual-control-values-changed';
52
+ values: Array<{
53
+ id: string;
54
+ value: unknown;
55
+ isUndefined: boolean;
56
+ }>;
40
57
  };
package/dist/index.d.ts CHANGED
@@ -1,5 +1,5 @@
1
1
  export { splitAnsi, stripAnsi } from './ansi';
2
- export { AddRenderRequest, ApiRoutes, ApplyCodemodRequest, ApplyCodemodResponse, ApplyVisualControlRequest, ApplyVisualControlResponse, CanUpdateDefaultPropsRequest, CanUpdateDefaultPropsResponse, CanUpdateSequencePropsRequest, CanUpdateSequencePropsResponse, CancelRenderRequest, SubscribeToSequencePropsRequest, SubscribeToSequencePropsResponse, UnsubscribeFromSequencePropsRequest, CancelRenderResponse, CopyStillToClipboardRequest, DeleteStaticFileRequest, DeleteStaticFileResponse, InstallPackageRequest, InstallPackageResponse, OpenInFileExplorerRequest, ProjectInfoRequest, ProjectInfoResponse, RemoveRenderRequest, RestartStudioRequest, RestartStudioResponse, SaveSequencePropsRequest, SaveSequencePropsResponse, SequenceNodePath, SimpleDiff, SubscribeToFileExistenceRequest, SubscribeToFileExistenceResponse, UnsubscribeFromFileExistenceRequest, UpdateAvailableRequest, UpdateAvailableResponse, UpdateDefaultPropsRequest, UpdateDefaultPropsResponse, } from './api-requests';
2
+ export { AddRenderRequest, ApiRoutes, ApplyCodemodRequest, ApplyCodemodResponse, ApplyVisualControlRequest, ApplyVisualControlResponse, CanUpdateDefaultPropsResponse, CanUpdateSequencePropsRequest, CanUpdateSequencePropsResponse, CancelRenderRequest, SubscribeToSequencePropsRequest, SubscribeToSequencePropsResponse, UnsubscribeFromSequencePropsRequest, CancelRenderResponse, CopyStillToClipboardRequest, DeleteStaticFileRequest, DeleteStaticFileResponse, InstallPackageRequest, InstallPackageResponse, OpenInFileExplorerRequest, ProjectInfoRequest, ProjectInfoResponse, RedoRequest, RedoResponse, RemoveRenderRequest, RestartStudioRequest, RestartStudioResponse, SaveSequencePropsRequest, SaveSequencePropsResponse, SequenceNodePath, SimpleDiff, SubscribeToDefaultPropsRequest, SubscribeToDefaultPropsResponse, SubscribeToFileExistenceRequest, SubscribeToFileExistenceResponse, UndoRequest, UndoResponse, UnsubscribeFromDefaultPropsRequest, UnsubscribeFromFileExistenceRequest, UpdateAvailableRequest, UpdateAvailableResponse, UpdateDefaultPropsRequest, UpdateDefaultPropsResponse, } from './api-requests';
3
3
  export type { ApplyVisualControlCodemod, RecastCodemod } from './codemods';
4
4
  export { DEFAULT_BUFFER_STATE_DELAY_IN_MILLISECONDS } from './default-buffer-state-delay-in-milliseconds';
5
5
  export { EventSourceEvent } from './event-source-event';
package/package.json CHANGED
@@ -3,7 +3,7 @@
3
3
  "url": "https://github.com/remotion-dev/remotion/tree/main/packages/studio-shared"
4
4
  },
5
5
  "name": "@remotion/studio-shared",
6
- "version": "4.0.437",
6
+ "version": "4.0.439",
7
7
  "description": "Internal package for shared objects between the Studio backend and frontend",
8
8
  "main": "dist",
9
9
  "sideEffects": false,
@@ -20,11 +20,11 @@
20
20
  "url": "https://github.com/remotion-dev/remotion/issues"
21
21
  },
22
22
  "dependencies": {
23
- "remotion": "4.0.437"
23
+ "remotion": "4.0.439"
24
24
  },
25
25
  "devDependencies": {
26
- "@remotion/renderer": "4.0.437",
27
- "@remotion/eslint-config-internal": "4.0.437",
26
+ "@remotion/renderer": "4.0.439",
27
+ "@remotion/eslint-config-internal": "4.0.439",
28
28
  "eslint": "9.19.0",
29
29
  "@typescript/native-preview": "7.0.0-dev.20260217.1"
30
30
  },