@cesdk/engine 1.68.0-nightly.20260123 → 1.68.0-rc.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/.browserslistrc +8 -0
- package/angular/index.d.ts +38 -0
- package/angular/index.js +146 -0
- package/assets/core/{cesdk-v1.68.0-nightly.20260123-2BTUQ2I7.wasm → cesdk-v1.68.0-rc.0-XJEVETUW.wasm} +0 -0
- package/assets/core/{worker-host-v1.68.0-nightly.20260123.js → worker-host-v1.68.0-rc.0.js} +1 -1
- package/cesdk.umd.js +1 -0
- package/index.d.ts +2 -2
- package/index.html +152 -0
- package/index.js +1 -1
- package/package.json +1 -1
- package/react/index.d.ts +115 -0
- package/react/index.js +1 -0
- package/vue/index.d.ts +162 -0
- package/vue/index.js +1 -0
- /package/assets/core/{cesdk-v1.68.0-nightly.20260123-MLEZSZ4D.data → cesdk-v1.68.0-rc.0-MLEZSZ4D.data} +0 -0
package/index.d.ts
CHANGED
|
@@ -103,7 +103,7 @@ export declare type AnimationEntry = {
|
|
|
103
103
|
export declare type AnimationGrowDirection = (typeof AnimationGrowDirectionValues)[number];
|
|
104
104
|
|
|
105
105
|
/** @public */
|
|
106
|
-
export declare const AnimationGrowDirectionValues: readonly ["Horizontal", "Vertical", "All"];
|
|
106
|
+
export declare const AnimationGrowDirectionValues: readonly ["Horizontal", "Vertical", "TopLeft", "TopRight", "BottomLeft", "BottomRight", "All"];
|
|
107
107
|
|
|
108
108
|
/** @public */
|
|
109
109
|
export declare type AnimationJumpLoopDirection = (typeof AnimationJumpLoopDirectionValues)[number];
|
|
@@ -7473,7 +7473,7 @@ export declare interface _Flip {
|
|
|
7473
7473
|
}
|
|
7474
7474
|
|
|
7475
7475
|
/** @public */
|
|
7476
|
-
export declare type FloatPropertyName = 'globalBoundingBox/height' | 'globalBoundingBox/width' | 'globalBoundingBox/x' | 'globalBoundingBox/y' | 'height' | 'lastFrame/height' | 'lastFrame/width' | 'lastFrame/x' | 'lastFrame/y' | 'position/x' | 'position/y' | 'rotation' | 'scene/dpi' | 'scene/pageDimensions/height' | 'scene/pageDimensions/width' | 'scene/pixelScaleFactor' | 'width' | 'camera/pixelRatio' | 'camera/resolution/height' | 'camera/resolution/width' | 'camera/zoomLevel' | 'dropShadow/blurRadius/x' | 'dropShadow/blurRadius/y' | 'dropShadow/offset/x' | 'dropShadow/offset/y' | 'page/margin/bottom' | 'page/margin/left' | 'page/margin/right' | 'page/margin/top' | 'playback/speed' | 'playback/volume' | 'stroke/width' | 'opacity' | 'backgroundColor/cornerRadius' | 'backgroundColor/paddingBottom' | 'backgroundColor/paddingLeft' | 'backgroundColor/paddingRight' | 'backgroundColor/paddingTop' | 'text/fontSize' | 'text/letterSpacing' | 'text/lineHeight' | 'text/maxAutomaticFontSize' | 'text/minAutomaticFontSize' | 'text/paragraphSpacing' | 'cutout/offset' | 'cutout/smoothing' | 'caption/fontSize' | 'caption/letterSpacing' | 'caption/lineHeight' | 'caption/maxAutomaticFontSize' | 'caption/minAutomaticFontSize' | 'caption/paragraphSpacing' | 'animation/slide/direction' | 'textAnimationOverlap' | 'animation/pan/direction' | 'animation/pan/distance' | 'animation/blur/intensity' | 'animation/crop_zoom/scale' | 'animation/spin/intensity' | 'animation/blur_loop/intensity' | 'animation/pulsating_loop/intensity' | 'animation/breathing_loop/intensity' | 'animation/jump_loop/intensity' | 'animation/sway_loop/intensity' | 'animation/spread_text/intensity' | 'animation/merge_text/intensity' | 'animation/ken_burns/travelDistanceRatio' | 'animation/ken_burns/zoomIntensity' | 'blur/uniform/intensity' | 'blur/linear/blurRadius' | 'blur/linear/x1' | 'blur/linear/x2' | 'blur/linear/y1' | 'blur/linear/y2' | 'blur/mirrored/blurRadius' | 'blur/mirrored/gradientSize' | 'blur/mirrored/size' | 'blur/mirrored/x1' | 'blur/mirrored/x2' | 'blur/mirrored/y1' | 'blur/mirrored/y2' | 'blur/radial/blurRadius' | 'blur/radial/gradientRadius' | 'blur/radial/radius' | 'blur/radial/x' | 'blur/radial/y' | 'effect/adjustments/blacks' | 'effect/adjustments/brightness' | 'effect/adjustments/clarity' | 'effect/adjustments/contrast' | 'effect/adjustments/exposure' | 'effect/adjustments/gamma' | 'effect/adjustments/highlights' | 'effect/adjustments/saturation' | 'effect/adjustments/shadows' | 'effect/adjustments/sharpness' | 'effect/adjustments/temperature' | 'effect/adjustments/whites' | 'effect/cross_cut/offset' | 'effect/cross_cut/slices' | 'effect/cross_cut/speedV' | 'effect/cross_cut/time' | 'effect/dot_pattern/blur' | 'effect/dot_pattern/dots' | 'effect/dot_pattern/size' | 'effect/duotone_filter/intensity' | 'effect/extrude_blur/amount' | 'effect/glow/amount' | 'effect/glow/darkness' | 'effect/glow/size' | 'effect/green_screen/colorMatch' | 'effect/green_screen/smoothness' | 'effect/green_screen/spill' | 'effect/half_tone/angle' | 'effect/half_tone/scale' | 'effect/linocut/scale' | 'effect/liquid/amount' | 'effect/liquid/scale' | 'effect/liquid/time' | 'effect/lut_filter/intensity' | 'effect/outliner/amount' | 'effect/outliner/passthrough' | 'effect/posterize/levels' | 'effect/radial_pixel/radius' | 'effect/radial_pixel/segments' | 'effect/recolor/brightnessMatch' | 'effect/recolor/colorMatch' | 'effect/recolor/smoothness' | 'effect/shifter/amount' | 'effect/shifter/angle' | 'effect/tilt_shift/amount' | 'effect/tilt_shift/position' | 'effect/tv_glitch/distortion' | 'effect/tv_glitch/distortion2' | 'effect/tv_glitch/rollSpeed' | 'effect/tv_glitch/speed' | 'effect/vignette/darkness' | 'effect/vignette/offset' | 'fill/gradient/linear/endPointX' | 'fill/gradient/linear/endPointY' | 'fill/gradient/linear/startPointX' | 'fill/gradient/linear/startPointY' | 'fill/gradient/radial/centerPointX' | 'fill/gradient/radial/centerPointY' | 'fill/gradient/radial/radius' | 'fill/gradient/conical/centerPointX' | 'fill/gradient/conical/centerPointY' | 'shape/rect/cornerRadiusBL' | 'shape/rect/cornerRadiusBR' | 'shape/rect/cornerRadiusTL' | 'shape/rect/cornerRadiusTR' | 'shape/polygon/cornerRadius' | 'shape/star/innerDiameter' | 'shape/vector_path/height' | 'shape/vector_path/width' | (string & {});
|
|
7476
|
+
export declare type FloatPropertyName = 'globalBoundingBox/height' | 'globalBoundingBox/width' | 'globalBoundingBox/x' | 'globalBoundingBox/y' | 'height' | 'lastFrame/height' | 'lastFrame/width' | 'lastFrame/x' | 'lastFrame/y' | 'position/x' | 'position/y' | 'rotation' | 'scene/dpi' | 'scene/pageDimensions/height' | 'scene/pageDimensions/width' | 'scene/pixelScaleFactor' | 'width' | 'camera/pixelRatio' | 'camera/resolution/height' | 'camera/resolution/width' | 'camera/zoomLevel' | 'dropShadow/blurRadius/x' | 'dropShadow/blurRadius/y' | 'dropShadow/offset/x' | 'dropShadow/offset/y' | 'page/margin/bottom' | 'page/margin/left' | 'page/margin/right' | 'page/margin/top' | 'playback/speed' | 'playback/volume' | 'stroke/width' | 'opacity' | 'backgroundColor/cornerRadius' | 'backgroundColor/paddingBottom' | 'backgroundColor/paddingLeft' | 'backgroundColor/paddingRight' | 'backgroundColor/paddingTop' | 'text/fontSize' | 'text/letterSpacing' | 'text/lineHeight' | 'text/maxAutomaticFontSize' | 'text/minAutomaticFontSize' | 'text/paragraphSpacing' | 'cutout/offset' | 'cutout/smoothing' | 'caption/fontSize' | 'caption/letterSpacing' | 'caption/lineHeight' | 'caption/maxAutomaticFontSize' | 'caption/minAutomaticFontSize' | 'caption/paragraphSpacing' | 'animation/slide/direction' | 'textAnimationOverlap' | 'animation/pan/direction' | 'animation/pan/distance' | 'animation/blur/intensity' | 'animation/grow/scaleFactor' | 'animation/crop_zoom/scale' | 'animation/spin/intensity' | 'animation/blur_loop/intensity' | 'animation/pulsating_loop/intensity' | 'animation/breathing_loop/intensity' | 'animation/jump_loop/intensity' | 'animation/sway_loop/intensity' | 'animation/spread_text/intensity' | 'animation/merge_text/intensity' | 'animation/ken_burns/travelDistanceRatio' | 'animation/ken_burns/zoomIntensity' | 'blur/uniform/intensity' | 'blur/linear/blurRadius' | 'blur/linear/x1' | 'blur/linear/x2' | 'blur/linear/y1' | 'blur/linear/y2' | 'blur/mirrored/blurRadius' | 'blur/mirrored/gradientSize' | 'blur/mirrored/size' | 'blur/mirrored/x1' | 'blur/mirrored/x2' | 'blur/mirrored/y1' | 'blur/mirrored/y2' | 'blur/radial/blurRadius' | 'blur/radial/gradientRadius' | 'blur/radial/radius' | 'blur/radial/x' | 'blur/radial/y' | 'effect/adjustments/blacks' | 'effect/adjustments/brightness' | 'effect/adjustments/clarity' | 'effect/adjustments/contrast' | 'effect/adjustments/exposure' | 'effect/adjustments/gamma' | 'effect/adjustments/highlights' | 'effect/adjustments/saturation' | 'effect/adjustments/shadows' | 'effect/adjustments/sharpness' | 'effect/adjustments/temperature' | 'effect/adjustments/whites' | 'effect/cross_cut/offset' | 'effect/cross_cut/slices' | 'effect/cross_cut/speedV' | 'effect/cross_cut/time' | 'effect/dot_pattern/blur' | 'effect/dot_pattern/dots' | 'effect/dot_pattern/size' | 'effect/duotone_filter/intensity' | 'effect/extrude_blur/amount' | 'effect/glow/amount' | 'effect/glow/darkness' | 'effect/glow/size' | 'effect/green_screen/colorMatch' | 'effect/green_screen/smoothness' | 'effect/green_screen/spill' | 'effect/half_tone/angle' | 'effect/half_tone/scale' | 'effect/linocut/scale' | 'effect/liquid/amount' | 'effect/liquid/scale' | 'effect/liquid/time' | 'effect/lut_filter/intensity' | 'effect/outliner/amount' | 'effect/outliner/passthrough' | 'effect/posterize/levels' | 'effect/radial_pixel/radius' | 'effect/radial_pixel/segments' | 'effect/recolor/brightnessMatch' | 'effect/recolor/colorMatch' | 'effect/recolor/smoothness' | 'effect/shifter/amount' | 'effect/shifter/angle' | 'effect/tilt_shift/amount' | 'effect/tilt_shift/position' | 'effect/tv_glitch/distortion' | 'effect/tv_glitch/distortion2' | 'effect/tv_glitch/rollSpeed' | 'effect/tv_glitch/speed' | 'effect/vignette/darkness' | 'effect/vignette/offset' | 'fill/gradient/linear/endPointX' | 'fill/gradient/linear/endPointY' | 'fill/gradient/linear/startPointX' | 'fill/gradient/linear/startPointY' | 'fill/gradient/radial/centerPointX' | 'fill/gradient/radial/centerPointY' | 'fill/gradient/radial/radius' | 'fill/gradient/conical/centerPointX' | 'fill/gradient/conical/centerPointY' | 'shape/rect/cornerRadiusBL' | 'shape/rect/cornerRadiusBR' | 'shape/rect/cornerRadiusTL' | 'shape/rect/cornerRadiusTR' | 'shape/polygon/cornerRadius' | 'shape/star/innerDiameter' | 'shape/vector_path/height' | 'shape/vector_path/width' | (string & {});
|
|
7477
7477
|
|
|
7478
7478
|
/**
|
|
7479
7479
|
* Represents a font.
|
package/index.html
ADDED
|
@@ -0,0 +1,152 @@
|
|
|
1
|
+
<!DOCTYPE html>
|
|
2
|
+
<html lang="en">
|
|
3
|
+
<head>
|
|
4
|
+
<title>CE.SDK Example</title>
|
|
5
|
+
<meta charset="UTF-8" />
|
|
6
|
+
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
|
|
7
|
+
<meta http-equiv="X-UA-Compatible" content="ie=edge" />
|
|
8
|
+
|
|
9
|
+
<style>
|
|
10
|
+
body {
|
|
11
|
+
margin: 0;
|
|
12
|
+
overflow: hidden;
|
|
13
|
+
}
|
|
14
|
+
|
|
15
|
+
html {
|
|
16
|
+
overscroll-behavior-x: contain;
|
|
17
|
+
}
|
|
18
|
+
|
|
19
|
+
#root {
|
|
20
|
+
height: 100vh;
|
|
21
|
+
}
|
|
22
|
+
|
|
23
|
+
.ubq-public {
|
|
24
|
+
/* Override CSS variables for a custom theme */
|
|
25
|
+
}
|
|
26
|
+
</style>
|
|
27
|
+
</head>
|
|
28
|
+
|
|
29
|
+
<body>
|
|
30
|
+
<div id="root"></div>
|
|
31
|
+
|
|
32
|
+
<script type="module">
|
|
33
|
+
import CreativeEditorSDK from './index.js';
|
|
34
|
+
|
|
35
|
+
window.onload = function () {
|
|
36
|
+
var href = window.location.href.split('?');
|
|
37
|
+
var config = {
|
|
38
|
+
baseURL: 'assets/',
|
|
39
|
+
role: 'Creator', // 'Creator', 'Adopter', 'Viewer'
|
|
40
|
+
callbacks: {
|
|
41
|
+
onSave: handleSave,
|
|
42
|
+
onLoad: handleLoad,
|
|
43
|
+
onExport: handleExport,
|
|
44
|
+
onUnsupportedBrowser: () => {
|
|
45
|
+
console.error('Unsupported Browser Detected');
|
|
46
|
+
}
|
|
47
|
+
},
|
|
48
|
+
ui: {
|
|
49
|
+
elements: {
|
|
50
|
+
view: 'default',
|
|
51
|
+
panels: {
|
|
52
|
+
settings: true
|
|
53
|
+
},
|
|
54
|
+
navigation: {
|
|
55
|
+
action: {
|
|
56
|
+
close: true,
|
|
57
|
+
back: true,
|
|
58
|
+
save: true,
|
|
59
|
+
load: true,
|
|
60
|
+
export: true
|
|
61
|
+
}
|
|
62
|
+
}
|
|
63
|
+
}
|
|
64
|
+
}
|
|
65
|
+
};
|
|
66
|
+
|
|
67
|
+
CreativeEditorSDK.create(document.getElementById('root'), config).then(
|
|
68
|
+
async (instance) => {
|
|
69
|
+
// Set the locale using the new API
|
|
70
|
+
instance.i18n.setLocale('en');
|
|
71
|
+
|
|
72
|
+
await Promise.all([
|
|
73
|
+
instance.addDefaultAssetSources(),
|
|
74
|
+
instance.addDemoAssetSources()
|
|
75
|
+
]);
|
|
76
|
+
await instance.createDesignScene();
|
|
77
|
+
}
|
|
78
|
+
);
|
|
79
|
+
};
|
|
80
|
+
|
|
81
|
+
var handleExport = function (blobs) {
|
|
82
|
+
const blob = blobs[0];
|
|
83
|
+
const element = document.createElement('a');
|
|
84
|
+
element.setAttribute('href', window.URL.createObjectURL(blob));
|
|
85
|
+
element.setAttribute(
|
|
86
|
+
'download',
|
|
87
|
+
`cesdk-${new Date().toISOString()}.png`
|
|
88
|
+
);
|
|
89
|
+
|
|
90
|
+
element.style.display = 'none';
|
|
91
|
+
document.body.appendChild(element);
|
|
92
|
+
|
|
93
|
+
element.click();
|
|
94
|
+
|
|
95
|
+
document.body.removeChild(element);
|
|
96
|
+
};
|
|
97
|
+
|
|
98
|
+
var handleSave = function (scene) {
|
|
99
|
+
const element = document.createElement('a');
|
|
100
|
+
const base64Data = btoa(unescape(encodeURIComponent(scene)));
|
|
101
|
+
element.setAttribute(
|
|
102
|
+
'href',
|
|
103
|
+
`data:application/octet-stream;base64,${base64Data}`
|
|
104
|
+
);
|
|
105
|
+
element.setAttribute(
|
|
106
|
+
'download',
|
|
107
|
+
`cesdk-${new Date().toISOString()}.scene`
|
|
108
|
+
);
|
|
109
|
+
|
|
110
|
+
element.style.display = 'none';
|
|
111
|
+
document.body.appendChild(element);
|
|
112
|
+
|
|
113
|
+
element.click();
|
|
114
|
+
|
|
115
|
+
document.body.removeChild(element);
|
|
116
|
+
};
|
|
117
|
+
|
|
118
|
+
var handleLoad = (function () {
|
|
119
|
+
const element = document.createElement('input');
|
|
120
|
+
element.setAttribute('type', 'file');
|
|
121
|
+
element.setAttribute('accept', '.scene');
|
|
122
|
+
|
|
123
|
+
element.style.display = 'none';
|
|
124
|
+
document.body.appendChild(element);
|
|
125
|
+
|
|
126
|
+
return () => {
|
|
127
|
+
return new Promise((resolve, reject) => {
|
|
128
|
+
element.onchange = (e) => {
|
|
129
|
+
const file = e.target.files[0];
|
|
130
|
+
if (file === undefined) {
|
|
131
|
+
reject(new Error('No files selected'));
|
|
132
|
+
} else {
|
|
133
|
+
const reader = new FileReader();
|
|
134
|
+
reader.readAsText(file, 'UTF-8');
|
|
135
|
+
|
|
136
|
+
reader.onload = (readerEvent) => {
|
|
137
|
+
const scene = readerEvent.target.result;
|
|
138
|
+
resolve(scene);
|
|
139
|
+
};
|
|
140
|
+
}
|
|
141
|
+
|
|
142
|
+
element.onchange = null;
|
|
143
|
+
element.value = '';
|
|
144
|
+
};
|
|
145
|
+
|
|
146
|
+
element.click();
|
|
147
|
+
});
|
|
148
|
+
};
|
|
149
|
+
})();
|
|
150
|
+
</script>
|
|
151
|
+
</body>
|
|
152
|
+
</html>
|