@cliquify.me/timeline 3.1.12 → 3.1.13

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.
@@ -0,0 +1,34 @@
1
+ import { IDisplay } from '@cliquify.me/types';
2
+ import { Rect, RectProps } from 'fabric';
3
+
4
+ export interface CompositionProps extends Pick<RectProps, "width" | "height" | "top" | "left"> {
5
+ id: string;
6
+ tScale: number;
7
+ display: IDisplay;
8
+ duration: number;
9
+ }
10
+ declare class Composition extends Rect {
11
+ static type: string;
12
+ itemType: string;
13
+ isSelected: boolean;
14
+ static getDefaults(): Record<string, any>;
15
+ static createControls(): {
16
+ controls: Record<string, any>;
17
+ };
18
+ static ownDefaults: {
19
+ rx: number;
20
+ ry: number;
21
+ objectCaching: boolean;
22
+ borderColor: string;
23
+ stroke: string;
24
+ strokeWidth: number;
25
+ fill: string;
26
+ borderOpacityWhenMoving: number;
27
+ hoverCursor: string;
28
+ };
29
+ constructor(props: CompositionProps);
30
+ setSelected(selected: boolean): void;
31
+ _render(ctx: CanvasRenderingContext2D): void;
32
+ updateSelected(ctx: CanvasRenderingContext2D): void;
33
+ }
34
+ export default Composition;
@@ -1,6 +1,7 @@
1
1
  import { Audio, Caption, Image, Text, Video } from '../objects';
2
2
  import { IAudio, IDisplay, ITextDetails, ITrackItem, ITrackItemAndDetails, ITrim, IVideo } from '@cliquify.me/types';
3
3
  import { default as Template } from '../objects/template';
4
+ import { default as Composition } from '../objects/composition';
4
5
 
5
6
  export declare const loadVideoObject: (item: IVideo, options: {
6
7
  tScale: number;
@@ -37,7 +38,13 @@ export declare const loadTemplateObject: (item: {
37
38
  }, options: {
38
39
  tScale: number;
39
40
  }) => Template;
41
+ export declare const loadCompositionObject: (item: {
42
+ id: string;
43
+ display: IDisplay;
44
+ }, options: {
45
+ tScale: number;
46
+ }) => Composition;
40
47
  export declare const loadMediaObject: (item: ITrackItemAndDetails, options: {
41
48
  tScale: number;
42
49
  sizesMap: Record<string, number>;
43
- }) => Image | Video | Audio | Text | Caption | Template | undefined;
50
+ }) => Image | Video | Audio | Text | Caption | Template | Composition | undefined;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@cliquify.me/timeline",
3
- "version": "3.1.12",
3
+ "version": "3.1.13",
4
4
  "private": false,
5
5
  "files": [
6
6
  "dist"
@@ -34,7 +34,7 @@
34
34
  "peerDependencies": {
35
35
  "@types/lodash-es": "^4.17.12",
36
36
  "@designcombo/events": "^1.0.2",
37
- "@cliquify.me/types": "3.1.12"
37
+ "@cliquify.me/types": "3.1.13"
38
38
  },
39
39
  "scripts": {
40
40
  "dev": "vite",