@rendley/sdk 1.5.2 → 1.6.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.
Files changed (31) hide show
  1. package/dist/Engine.d.ts +20 -13
  2. package/dist/index.cjs +1 -1
  3. package/dist/index.d.ts +2 -1
  4. package/dist/index.js +1 -1
  5. package/dist/modules/clip/Clip.d.ts +45 -44
  6. package/dist/modules/clip/ClipStyle.d.ts +3 -2
  7. package/dist/modules/clip/clips/audio/AudioClip.d.ts +12 -12
  8. package/dist/modules/clip/clips/custom/CustomClip.d.ts +9 -9
  9. package/dist/modules/clip/clips/htmlText/HtmlTextClip.d.ts +35 -35
  10. package/dist/modules/clip/clips/index.d.ts +1 -0
  11. package/dist/modules/clip/clips/lottie/LottieClip.d.ts +26 -11
  12. package/dist/modules/clip/clips/shape/ShapeClip.d.ts +11 -11
  13. package/dist/modules/clip/clips/shape/ShapeStyle.d.ts +2 -2
  14. package/dist/modules/clip/clips/text/TextClip.d.ts +11 -11
  15. package/dist/modules/clip/clips/text/TextStyle.d.ts +15 -6
  16. package/dist/modules/clip/clips/video/VideoClip.d.ts +12 -12
  17. package/dist/modules/display/Display.d.ts +3 -3
  18. package/dist/modules/event-emitter/types/EventEmitter.types.d.ts +20 -1
  19. package/dist/modules/filter/Effect.d.ts +1 -1
  20. package/dist/modules/filter/Filter.d.ts +3 -3
  21. package/dist/modules/layer/Layer.d.ts +3 -1
  22. package/dist/modules/library/Library.d.ts +3 -1
  23. package/dist/modules/library/Subtitles.d.ts +2 -2
  24. package/dist/modules/{subtitleManager → subtitles}/SubtitleManager.d.ts +86 -86
  25. package/dist/modules/timeline/Timeline.d.ts +2 -0
  26. package/dist/modules/undo/UndoManager.d.ts +35 -0
  27. package/dist/modules/undo/UndoManager.types.d.ts +286 -0
  28. package/dist/modules/undo/index.d.ts +2 -0
  29. package/dist/utils/animation/animation.d.ts +3 -3
  30. package/package.json +3 -2
  31. /package/dist/modules/{subtitleManager → subtitles}/index.d.ts +0 -0
@@ -0,0 +1,286 @@
1
+ import { TextBlock } from "../library";
2
+ import { HighlightAnimationEnum } from "../subtitles";
3
+ export declare enum UndoActionEnum {
4
+ MEDIA_ADD = "media-add",
5
+ MEDIA_REMOVE = "media-remove",
6
+ MEDIA_REPLACE = "media-replace",
7
+ LAYER_ADD = "layer-add",
8
+ LAYER_REMOVE = "layer-remove",
9
+ CLIP_ADD = "clip-add",
10
+ CLIP_REMOVE = "clip-remove",
11
+ CLIP_START_TIME = "clip-start-time",
12
+ CLIP_RIGHT_TRIM = "clip-right-trim",
13
+ CLIP_LEFT_TRIM = "clip-left-trim",
14
+ CLIP_MOVE_TO_LAYER = "clip-move-to-layer",
15
+ CLIP_SUBTITLES_SETTINGS = "clip-subtitles-settings",
16
+ CLIP_STYLE_POSITION = "clip-style-position",
17
+ CLIP_STYLE_SCALE = "clip-style-scale",
18
+ CLIP_STYLE_ROTATION = "clip-style-rotation",
19
+ CLIP_STYLE_ALPHA = "clip-style-alpha",
20
+ CLIP_STYLE_CORNER_RADIUS = "clip-style-corner-radius",
21
+ CLIP_TEXT_TEXT = "clip-text-text",
22
+ CLIP_TEXT_COLOR = "clip-text-color",
23
+ CLIP_TEXT_FONT_SIZE = "clip-text-font-size",
24
+ CLIP_TEXT_FONT_WEIGHT = "clip-text-font-weight",
25
+ CLIP_TEXT_FONT_FAMILY = "clip-text-font-family",
26
+ CLIP_TEXT_TEXT_ALIGN = "clip-text-text-align",
27
+ CLIP_TEXT_FONT_STYLE = "clip-text-font-style",
28
+ CLIP_TEXT_BACKGROUND_COLOR = "clip-text-background-color",
29
+ CLIP_TEXT_WORD_WRAP_WIDTH = "clip-text-word-wrap-width",
30
+ CLIP_TEXT_STROKE_COLOR = "clip-text-stroke-color",
31
+ CLIP_TEXT_STROKE_THICKNESS = "clip-text-stroke-thickness",
32
+ CLIP_HTML_TEXT = "clip-html-text",
33
+ CLIP_HTML_STYLE = "clip-html-style",
34
+ CLIP_LOTTIE_PROPERTY = "clip-lottie-property",
35
+ TRANSITION_ADD = "transition-add",
36
+ TRANSITION_REMOVE = "transition-remove",
37
+ FILTER_ADD = "filter-add",
38
+ FILTER_REMOVE = "filter-remove",
39
+ EFFECT_ADD = "effect-add",
40
+ EFFECT_REMOVE = "effect-remove",
41
+ SUBTITLES_TEXT_MODE = "subtitles-text-mode",
42
+ SUBTITLES_MAIN_TEXT_STYLE = "subtitles-main-text-style",
43
+ SUBTITLES_HIGHLIGHT_TEXT_STYLE = "subtitles-highlighted-text-style",
44
+ SUBTITLES_HIGHLIGHT_ANIMATION = "subtitles-highlight-animation",
45
+ LIBRARY_SUBTITLES_ADD = "library-subtitles-add",
46
+ LIBRARY_SUBTITLES_REMOVE = "library-subtitles-remove",
47
+ LIBRARY_SUBTITLES_ADD_BLOCK = "library-subtitles-add-block",
48
+ LIBRARY_SUBTITLES_REMOVE_BLOCK = "library-subtitles-remove-block",
49
+ LIBRARY_SUBTITLES_UPDATE_BLOCK = "library-subtitles-update-block",
50
+ LIBRARY_SUBTITLES_SET_BLOCKS = "library-subtitles-set-blocks",
51
+ DISPLAY_BACKGROUND_COLOR = "display-background-color",
52
+ DISPLAY_RESOLUTION = "display-resolution"
53
+ }
54
+ export type UndoActionMappings = {
55
+ [UndoActionEnum.MEDIA_ADD]: {
56
+ mediaDataId: string;
57
+ };
58
+ [UndoActionEnum.MEDIA_REMOVE]: {
59
+ mediaDataId: string;
60
+ data: any;
61
+ };
62
+ [UndoActionEnum.MEDIA_REPLACE]: {
63
+ mediaDataId: string;
64
+ prevMediaData: any;
65
+ };
66
+ [UndoActionEnum.LAYER_ADD]: {
67
+ layerId: string;
68
+ };
69
+ [UndoActionEnum.LAYER_REMOVE]: {
70
+ layerId: string;
71
+ data: any;
72
+ layerIndex: number;
73
+ };
74
+ [UndoActionEnum.CLIP_ADD]: {
75
+ clipId: string;
76
+ };
77
+ [UndoActionEnum.CLIP_REMOVE]: {
78
+ clipId: string;
79
+ layerId: string;
80
+ data: any;
81
+ };
82
+ [UndoActionEnum.CLIP_START_TIME]: {
83
+ clipId: string;
84
+ value: number;
85
+ };
86
+ [UndoActionEnum.CLIP_RIGHT_TRIM]: {
87
+ clipId: string;
88
+ value: number;
89
+ };
90
+ [UndoActionEnum.CLIP_LEFT_TRIM]: {
91
+ clipId: string;
92
+ value: number;
93
+ };
94
+ [UndoActionEnum.CLIP_MOVE_TO_LAYER]: {
95
+ clipId: string;
96
+ fromLayerId: string;
97
+ toLayerId: string;
98
+ };
99
+ [UndoActionEnum.CLIP_SUBTITLES_SETTINGS]: {
100
+ clipId: string;
101
+ prevSubtitlesId: string | undefined;
102
+ prevOffset: number;
103
+ subtitlesId: string | undefined;
104
+ offset: number;
105
+ };
106
+ [UndoActionEnum.CLIP_STYLE_POSITION]: {
107
+ clipId: string;
108
+ value: [number, number];
109
+ };
110
+ [UndoActionEnum.CLIP_STYLE_SCALE]: {
111
+ clipId: string;
112
+ value: [number, number];
113
+ };
114
+ [UndoActionEnum.CLIP_STYLE_ROTATION]: {
115
+ clipId: string;
116
+ value: number;
117
+ };
118
+ [UndoActionEnum.CLIP_STYLE_ALPHA]: {
119
+ clipId: string;
120
+ value: number;
121
+ };
122
+ [UndoActionEnum.CLIP_STYLE_CORNER_RADIUS]: {
123
+ clipId: string;
124
+ cornerRadius: number[];
125
+ relative: boolean;
126
+ };
127
+ [UndoActionEnum.CLIP_TEXT_TEXT]: {
128
+ clipId: string;
129
+ prevText: string;
130
+ text: string;
131
+ };
132
+ [UndoActionEnum.CLIP_TEXT_COLOR]: {
133
+ clipId: string;
134
+ prevColor: string;
135
+ color: string;
136
+ };
137
+ [UndoActionEnum.CLIP_TEXT_FONT_SIZE]: {
138
+ clipId: string;
139
+ prevFontSize: number;
140
+ fontSize: number;
141
+ };
142
+ [UndoActionEnum.CLIP_TEXT_FONT_WEIGHT]: {
143
+ clipId: string;
144
+ prevFontWeight: string;
145
+ fontWeight: string;
146
+ };
147
+ [UndoActionEnum.CLIP_TEXT_FONT_FAMILY]: {
148
+ clipId: string;
149
+ prevFontFamily: string;
150
+ fontFamily: string;
151
+ };
152
+ [UndoActionEnum.CLIP_TEXT_TEXT_ALIGN]: {
153
+ clipId: string;
154
+ prevTextAlign: string;
155
+ textAlign: string;
156
+ };
157
+ [UndoActionEnum.CLIP_TEXT_FONT_STYLE]: {
158
+ clipId: string;
159
+ prevFontStyle: string;
160
+ fontStyle: string;
161
+ };
162
+ [UndoActionEnum.CLIP_TEXT_BACKGROUND_COLOR]: {
163
+ clipId: string;
164
+ prevBackgroundColor: string | null;
165
+ backgroundColor: string | null;
166
+ };
167
+ [UndoActionEnum.CLIP_TEXT_WORD_WRAP_WIDTH]: {
168
+ clipId: string;
169
+ prevWordWrapWidth: number | null;
170
+ wordWrapWidth: number | null;
171
+ };
172
+ [UndoActionEnum.CLIP_TEXT_STROKE_COLOR]: {
173
+ clipId: string;
174
+ prevStrokeColor: string;
175
+ strokeColor: string;
176
+ };
177
+ [UndoActionEnum.CLIP_TEXT_STROKE_THICKNESS]: {
178
+ clipId: string;
179
+ prevStrokeThickness: number;
180
+ strokeThickness: number;
181
+ };
182
+ [UndoActionEnum.CLIP_HTML_TEXT]: {
183
+ clipId: string;
184
+ prevText: string;
185
+ text: string;
186
+ };
187
+ [UndoActionEnum.CLIP_HTML_STYLE]: {
188
+ clipId: string;
189
+ prevStyle: any;
190
+ style: any;
191
+ };
192
+ [UndoActionEnum.CLIP_LOTTIE_PROPERTY]: {
193
+ clipId: string;
194
+ property: string;
195
+ prevValue: any;
196
+ value: any;
197
+ };
198
+ [UndoActionEnum.TRANSITION_ADD]: {
199
+ layerId: string;
200
+ transition: any;
201
+ prevTransitions: any[];
202
+ };
203
+ [UndoActionEnum.TRANSITION_REMOVE]: {
204
+ layerId: string;
205
+ transition: any;
206
+ };
207
+ [UndoActionEnum.FILTER_ADD]: {
208
+ clipId: string;
209
+ filter: any;
210
+ prevFilters: any[];
211
+ };
212
+ [UndoActionEnum.FILTER_REMOVE]: {
213
+ clipId: string;
214
+ filter: any;
215
+ };
216
+ [UndoActionEnum.EFFECT_ADD]: {
217
+ clipId: string;
218
+ effect: any;
219
+ prevEffects: any[];
220
+ };
221
+ [UndoActionEnum.EFFECT_REMOVE]: {
222
+ clipId: string;
223
+ effect: any;
224
+ };
225
+ [UndoActionEnum.SUBTITLES_TEXT_MODE]: {
226
+ prevTextMode: string;
227
+ textMode: string;
228
+ };
229
+ [UndoActionEnum.SUBTITLES_MAIN_TEXT_STYLE]: {
230
+ prevMainTextStyle: any;
231
+ mainTextStyle: any;
232
+ };
233
+ [UndoActionEnum.SUBTITLES_HIGHLIGHT_TEXT_STYLE]: {
234
+ prevHighlightTextStyle: any;
235
+ highlightTextStyle: any;
236
+ };
237
+ [UndoActionEnum.SUBTITLES_HIGHLIGHT_ANIMATION]: {
238
+ prevAnimation: HighlightAnimationEnum;
239
+ prevSpeed: number;
240
+ animation: HighlightAnimationEnum;
241
+ speed: number;
242
+ };
243
+ [UndoActionEnum.LIBRARY_SUBTITLES_ADD]: {
244
+ subtitlesId: string;
245
+ };
246
+ [UndoActionEnum.LIBRARY_SUBTITLES_REMOVE]: {
247
+ subtitlesId: string;
248
+ subtitles: any;
249
+ };
250
+ [UndoActionEnum.LIBRARY_SUBTITLES_ADD_BLOCK]: {
251
+ subtitlesId: string;
252
+ index: number;
253
+ };
254
+ [UndoActionEnum.LIBRARY_SUBTITLES_REMOVE_BLOCK]: {
255
+ subtitlesId: string;
256
+ index: number;
257
+ textBlock: TextBlock;
258
+ };
259
+ [UndoActionEnum.LIBRARY_SUBTITLES_UPDATE_BLOCK]: {
260
+ subtitlesId: string;
261
+ index: number;
262
+ prevTextBlock: TextBlock;
263
+ };
264
+ [UndoActionEnum.LIBRARY_SUBTITLES_SET_BLOCKS]: {
265
+ subtitlesId: string;
266
+ prevTextBlocks: TextBlock[];
267
+ };
268
+ [UndoActionEnum.DISPLAY_BACKGROUND_COLOR]: {
269
+ prevBackgroundColor: string;
270
+ backgroundColor: string;
271
+ };
272
+ [UndoActionEnum.DISPLAY_RESOLUTION]: {
273
+ prevResolution: [number, number];
274
+ resolution: [number, number];
275
+ };
276
+ };
277
+ export declare class UndoRecord {
278
+ action: UndoActionEnum;
279
+ data: any;
280
+ constructor(action: UndoActionEnum, data: any);
281
+ }
282
+ export declare class UndoGroup {
283
+ records: UndoRecord[];
284
+ name: string;
285
+ constructor(name: string);
286
+ }
@@ -0,0 +1,2 @@
1
+ export * from "./UndoManager";
2
+ export * from "./UndoManager.types";
@@ -110,9 +110,9 @@ export declare const PropertyAnimationSchema: z.ZodObject<{
110
110
  relativeProperty?: string | undefined;
111
111
  }>, "many">;
112
112
  }, "strip", z.ZodTypeAny, {
113
- property: string;
114
113
  inOutOfRange: OutOfRangeEnum;
115
114
  outOutOfRange: OutOfRangeEnum;
115
+ property: string;
116
116
  keyframes: {
117
117
  time: number;
118
118
  value: string | number;
@@ -163,9 +163,9 @@ export declare const AnimationDataSchema: z.ZodObject<{
163
163
  relativeProperty?: string | undefined;
164
164
  }>, "many">;
165
165
  }, "strip", z.ZodTypeAny, {
166
- property: string;
167
166
  inOutOfRange: OutOfRangeEnum;
168
167
  outOutOfRange: OutOfRangeEnum;
168
+ property: string;
169
169
  keyframes: {
170
170
  time: number;
171
171
  value: string | number;
@@ -190,9 +190,9 @@ export declare const AnimationDataSchema: z.ZodObject<{
190
190
  inOutOfRange: OutOfRangeEnum;
191
191
  outOutOfRange: OutOfRangeEnum;
192
192
  propertyAnimations: {
193
- property: string;
194
193
  inOutOfRange: OutOfRangeEnum;
195
194
  outOutOfRange: OutOfRangeEnum;
195
+ property: string;
196
196
  keyframes: {
197
197
  time: number;
198
198
  value: string | number;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@rendley/sdk",
3
- "version": "1.5.2",
3
+ "version": "1.6.0",
4
4
  "license": "LICENSE",
5
5
  "author": "Onix Technologies",
6
6
  "homepage": "https://rendley.com",
@@ -60,7 +60,8 @@
60
60
  "postinstall-postinstall": "2.1.0",
61
61
  "prettier": "3.1.1",
62
62
  "ts-jest": "29.1.1",
63
- "typedoc": "0.25.12",
63
+ "typedoc": "0.27.2",
64
+ "typedoc-plugin-markdown": "4.3.1",
64
65
  "typescript": "5.3.3",
65
66
  "vite": "^5.4.9",
66
67
  "vite-plugin-dts": "3.7.2"