@imgly/plugin-ai-apps-web 1.86.0-nightly.20261102 → 1.87.0-nightly.20261104
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/dist/index.d.ts +66 -5
- package/dist/index.mjs +122 -216
- package/dist/index.mjs.map +1 -7
- package/package.json +14 -14
- package/dist/.tsbuildinfo +0 -1
- package/dist/ActiveAssetSource.d.ts +0 -94
- package/dist/constants.d.ts +0 -1
- package/dist/plugin.d.ts +0 -5
- package/dist/types.d.ts +0 -62
package/dist/index.d.ts
CHANGED
|
@@ -1,7 +1,68 @@
|
|
|
1
|
-
import
|
|
1
|
+
import CreativeEditorSDK from "@cesdk/cesdk-js";
|
|
2
|
+
import { OutputKind, Provider } from "@imgly/plugin-ai-generation-web";
|
|
3
|
+
type GetProvider<K extends OutputKind> = ({ cesdk }: {
|
|
4
|
+
cesdk: CreativeEditorSDK;
|
|
5
|
+
}) => Promise<Provider<K, any, any>>;
|
|
6
|
+
/**
|
|
7
|
+
* The provider configuration that maps capabilities
|
|
8
|
+
* to actual provider.
|
|
9
|
+
*/
|
|
10
|
+
interface Providers {
|
|
11
|
+
/**
|
|
12
|
+
* Provider for text generation on text blocks.
|
|
13
|
+
*/
|
|
14
|
+
text2text?: GetProvider<'text'> | GetProvider<'text'>[];
|
|
15
|
+
/**
|
|
16
|
+
* Provider for image generation based on a prompt alone.
|
|
17
|
+
*/
|
|
18
|
+
text2image?: GetProvider<'image'> | GetProvider<'image'>[];
|
|
19
|
+
/**
|
|
20
|
+
* Provider for image generation based on a prompt and an image.
|
|
21
|
+
*/
|
|
22
|
+
image2image?: GetProvider<'image'> | GetProvider<'image'>[];
|
|
23
|
+
/**
|
|
24
|
+
* Provider for video generation based on a prompt alone.
|
|
25
|
+
*/
|
|
26
|
+
text2video?: GetProvider<'video'> | GetProvider<'video'>[];
|
|
27
|
+
/**
|
|
28
|
+
* Provider for video generation based on a prompt and an image.
|
|
29
|
+
*/
|
|
30
|
+
image2video?: GetProvider<'video'> | GetProvider<'video'>[];
|
|
31
|
+
/**
|
|
32
|
+
* Provider for speech generation based on a prompt alone.
|
|
33
|
+
*/
|
|
34
|
+
text2speech?: GetProvider<'audio'> | GetProvider<'audio'>[];
|
|
35
|
+
/**
|
|
36
|
+
* Provider for sound effect generation based on a prompt alone.
|
|
37
|
+
*/
|
|
38
|
+
text2sound?: GetProvider<'audio'> | GetProvider<'audio'>[];
|
|
39
|
+
/**
|
|
40
|
+
* Provider for sticker generation based on a prompt alone.
|
|
41
|
+
*/
|
|
42
|
+
text2sticker?: any | any[];
|
|
43
|
+
}
|
|
44
|
+
interface PluginConfiguration {
|
|
45
|
+
providers: Providers;
|
|
46
|
+
/**
|
|
47
|
+
* Whether to enable debug mode. Will print additional debug information
|
|
48
|
+
*/
|
|
49
|
+
debug?: boolean;
|
|
50
|
+
/**
|
|
51
|
+
* If true the generation process wll be replaced with a dummy generation.
|
|
52
|
+
* Useful for testing the UI without actually generating images.
|
|
53
|
+
*/
|
|
54
|
+
dryRun?: boolean;
|
|
55
|
+
/**
|
|
56
|
+
* Base URL used for the UI assets used in the plugin.
|
|
57
|
+
*
|
|
58
|
+
* By default, we load the assets from the IMG.LY CDN. You can copy the assets.
|
|
59
|
+
* from the `/assets` folder to your own server and set the base URL to your server.
|
|
60
|
+
*/
|
|
61
|
+
baseURL?: string;
|
|
62
|
+
}
|
|
2
63
|
declare const Plugin: (pluginConfiguration: PluginConfiguration) => {
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
64
|
+
initialize: (context: import("@cesdk/cesdk-js").EditorPluginContext) => void | Promise<void>;
|
|
65
|
+
name: string;
|
|
66
|
+
version: string;
|
|
6
67
|
};
|
|
7
|
-
export default
|
|
68
|
+
export { Plugin as default };
|