@cntrl-site/sdk 1.5.4 → 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.
@@ -44,6 +44,10 @@ const VideoItemSchema = ItemBase_schema_1.ItemBaseSchema.extend({
44
44
  }).nullable()),
45
45
  layoutParams: zod_1.z.record(zod_1.z.object({
46
46
  autoplay: zod_1.z.boolean(),
47
+ scrollPlayback: zod_1.z.object({
48
+ from: zod_1.z.number(),
49
+ to: zod_1.z.number()
50
+ }).nullable(),
47
51
  opacity: zod_1.z.number().nonnegative(),
48
52
  radius: zod_1.z.number(),
49
53
  strokeWidth: zod_1.z.number(),
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@cntrl-site/sdk",
3
- "version": "1.5.4",
3
+ "version": "1.6.0",
4
4
  "description": "Generic SDK for use in public websites.",
5
5
  "main": "lib/index.js",
6
6
  "types": "src/index.ts",
@@ -64,6 +64,10 @@ const VideoItemSchema = ItemBaseSchema.extend({
64
64
  layoutParams: z.record(
65
65
  z.object({
66
66
  autoplay: z.boolean(),
67
+ scrollPlayback: z.object({
68
+ from: z.number(),
69
+ to: z.number()
70
+ }).nullable(),
67
71
  opacity: z.number().nonnegative(),
68
72
  radius: z.number(),
69
73
  strokeWidth: z.number(),
@@ -55,7 +55,7 @@ interface VideoCommonParams extends MediaCommonParams {}
55
55
  interface ImageCommonParams extends MediaCommonParams {
56
56
  hasGLEffect?: boolean;
57
57
  fragmentShader?: string;
58
- cursor?: FXCursor;
58
+ FXCursor?: FXCursor;
59
59
  }
60
60
 
61
61
  interface RichTextCommonParams {
@@ -117,6 +117,7 @@ interface ImageLayoutParams extends MediaLayoutParams {}
117
117
 
118
118
  interface VideoLayoutParams extends MediaLayoutParams {
119
119
  autoplay: boolean;
120
+ scrollPlayback: ScrollPlaybackParams | null;
120
121
  }
121
122
 
122
123
  interface RichTextLayoutParams {
@@ -148,6 +149,11 @@ interface RectangleLayoutParams {
148
149
  blurMode: 'default' | 'backdrop';
149
150
  }
150
151
 
152
+ export interface ScrollPlaybackParams {
153
+ from: number;
154
+ to: number;
155
+ }
156
+
151
157
  export interface StickyParams {
152
158
  from: number;
153
159
  to?: number;