@orangecatai/adgen-canvas 0.0.19 → 0.0.21

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 (36) hide show
  1. package/dist/dev/{chunk-SFB47GDQ.js → chunk-RD5LX7MN.js} +2 -2
  2. package/dist/dev/{chunk-JFIHKE5E.js → chunk-WFKR6OGI.js} +3 -15
  3. package/dist/dev/{chunk-JFIHKE5E.js.map → chunk-WFKR6OGI.js.map} +2 -2
  4. package/dist/dev/data/{image-OXVYDFFE.js → image-DSU2H6P5.js} +3 -3
  5. package/dist/dev/index.css +391 -12
  6. package/dist/dev/index.css.map +3 -3
  7. package/dist/dev/index.js +4910 -4527
  8. package/dist/dev/index.js.map +4 -4
  9. package/dist/dev/subset-shared.chunk.js +1 -1
  10. package/dist/dev/subset-worker.chunk.js +1 -1
  11. package/dist/prod/{chunk-7XQHY7WT.js → chunk-OWNL6YOR.js} +1 -1
  12. package/dist/prod/{chunk-5GYFLSBF.js → chunk-RXJEXEKA.js} +3 -3
  13. package/dist/prod/data/image-I7MZ4QNS.js +1 -0
  14. package/dist/prod/index.css +1 -1
  15. package/dist/prod/index.js +94 -68
  16. package/dist/prod/subset-shared.chunk.js +1 -1
  17. package/dist/prod/subset-worker.chunk.js +1 -1
  18. package/dist/types/excalidraw/components/AIChatPanel.d.ts +36 -8
  19. package/dist/types/excalidraw/components/ImageEditToolbar.d.ts +0 -1
  20. package/dist/types/excalidraw/components/ImageGeneratorPanel.d.ts +23 -10
  21. package/dist/types/excalidraw/components/StockImagePanel.d.ts +49 -0
  22. package/dist/types/excalidraw/components/ai-chat/agentLoop.d.ts +8 -2
  23. package/dist/types/excalidraw/components/ai-chat/audioUtils.d.ts +0 -5
  24. package/dist/types/excalidraw/components/ai-chat/canvasTools.d.ts +15 -2
  25. package/dist/types/excalidraw/components/ai-chat/reviewerAgent.d.ts +3 -2
  26. package/dist/types/excalidraw/components/auto-resize/AutoResizePanel.d.ts +2 -2
  27. package/dist/types/excalidraw/components/auto-resize/autoResizeEngine.d.ts +1 -2
  28. package/dist/types/excalidraw/index.d.ts +2 -0
  29. package/dist/types/excalidraw/types.d.ts +18 -28
  30. package/dist/types/excalidraw/utils/imageApi.d.ts +1 -0
  31. package/package.json +1 -1
  32. package/dist/prod/data/image-FRJAQJ62.js +0 -1
  33. package/dist/types/excalidraw/utils/geminiApiKey.d.ts +0 -1
  34. package/dist/types/excalidraw/utils/leonardoApiKey.d.ts +0 -1
  35. /package/dist/dev/{chunk-SFB47GDQ.js.map → chunk-RD5LX7MN.js.map} +0 -0
  36. /package/dist/dev/data/{image-OXVYDFFE.js.map → image-DSU2H6P5.js.map} +0 -0
@@ -1 +1 @@
1
- import{a,b,c,d}from"./chunk-Z5NKEFVG.js";import"./chunk-7XQHY7WT.js";import"./chunk-SRAX5OIU.js";export{a as Commands,b as subsetToBase64,c as subsetToBinary,d as toBase64};
1
+ import{a,b,c,d}from"./chunk-Z5NKEFVG.js";import"./chunk-OWNL6YOR.js";import"./chunk-SRAX5OIU.js";export{a as Commands,b as subsetToBase64,c as subsetToBinary,d as toBase64};
@@ -1 +1 @@
1
- import{a as r,c as t}from"./chunk-Z5NKEFVG.js";import"./chunk-7XQHY7WT.js";import"./chunk-SRAX5OIU.js";var s=import.meta.url?new URL(import.meta.url):void 0;typeof window>"u"&&typeof self<"u"&&(self.onmessage=async e=>{switch(e.data.command){case r.Subset:let a=await t(e.data.arrayBuffer,e.data.codePoints);self.postMessage(a,{transfer:[a]});break}});export{s as WorkerUrl};
1
+ import{a as r,c as t}from"./chunk-Z5NKEFVG.js";import"./chunk-OWNL6YOR.js";import"./chunk-SRAX5OIU.js";var s=import.meta.url?new URL(import.meta.url):void 0;typeof window>"u"&&typeof self<"u"&&(self.onmessage=async e=>{switch(e.data.command){case r.Subset:let a=await t(e.data.arrayBuffer,e.data.codePoints);self.postMessage(a,{transfer:[a]});break}});export{s as WorkerUrl};
@@ -11,8 +11,10 @@ export type ChatMessage = {
11
11
  toolActions?: ToolAction[];
12
12
  attachments?: Array<{
13
13
  name: string;
14
- type: "image" | "text";
14
+ type: "image" | "text" | "pdf" | "docx";
15
15
  dataUrl?: string;
16
+ textContent?: string;
17
+ s3Key?: string;
16
18
  }>;
17
19
  /** Reviewer feedback attached to an assistant message after HTML ad generation */
18
20
  reviewFeedback?: ReviewerFeedback;
@@ -29,9 +31,19 @@ export type AIChatPanelRef = {
29
31
  export type AIChatPanelProps = {
30
32
  isOpen: boolean;
31
33
  onClose: () => void;
32
- apiKey?: string;
34
+ /**
35
+ * Host proxy URL for the chat / agent loop / reviewer OpenRouter calls. The
36
+ * SDK POSTs the OpenRouter request body here; the host injects the API key,
37
+ * gates credits, and streams the response back. Keeps the provider key out of
38
+ * the browser.
39
+ */
40
+ chatUrl?: string;
41
+ /**
42
+ * Host proxy URL for the agent's generate_image tool. Same contract as
43
+ * `chatUrl`. Keeps the provider key out of the browser.
44
+ */
45
+ imageGenUrl?: string;
33
46
  excalidrawAPI?: ExcalidrawImperativeAPI;
34
- geminiApiKey?: string;
35
47
  initialMessages?: ChatMessage[];
36
48
  initialSessionId?: string;
37
49
  initialSessions?: ChatSession[];
@@ -41,6 +53,15 @@ export type AIChatPanelProps = {
41
53
  title: string;
42
54
  }) => void;
43
55
  onSessionSwitch?: (sessionId: string) => void;
56
+ onBeforeFileUpload?: (files: Array<{
57
+ name: string;
58
+ type: "image" | "pdf" | "text" | "docx";
59
+ mimeType: string;
60
+ dataUrl?: string;
61
+ textContent?: string;
62
+ }>, sessionId: string) => Promise<Array<{
63
+ s3Key: string;
64
+ } | null>>;
44
65
  onBeforeSend?: (ctx: {
45
66
  hasVoice: boolean;
46
67
  }) => Promise<{
@@ -57,19 +78,26 @@ export type AIChatPanelProps = {
57
78
  onAfterImageGen?: () => void;
58
79
  /**
59
80
  * OpenRouter model tag for the chat system (both plain chat and agent loop).
60
- * @default "google/gemini-3.1-flash-lite-preview"
81
+ * @default "minimax/minimax-m3"
61
82
  * @example "openai/gpt-4o" or "anthropic/claude-sonnet-4"
62
83
  */
63
84
  chatModel?: string;
64
85
  /**
65
86
  * OpenRouter model tag for voice/speech-to-text transcription.
66
- * @default "mistralai/voxtral-small-24b-2507"
87
+ * @default "mistralai/voxtral-mini-transcribe"
67
88
  */
68
89
  voiceModel?: string;
69
90
  /**
70
- * Gemini model ID used by the agent's generate_image tool.
71
- * @default "gemini-3.1-flash-image-preview"
72
- * @example "gemini-2.0-flash-preview-image-generation"
91
+ * URL to POST `{ audio: string; format: string }` for server-side transcription.
92
+ * When provided, the SDK routes mic audio through this endpoint instead of
93
+ * calling OpenRouter directly, so the API key never needs to be in the browser.
94
+ * The endpoint must return `{ text: string }`.
95
+ */
96
+ transcribeUrl?: string;
97
+ /**
98
+ * OpenRouter model ID used by the agent's generate_image tool.
99
+ * @default "google/gemini-3.1-flash-image-preview"
100
+ * @example "google/gemini-2.5-flash-image"
73
101
  */
74
102
  agentImageModel?: string;
75
103
  /**
@@ -3,7 +3,6 @@ import type { ExcalidrawImageElement, NonDeletedExcalidrawElement } from "@orang
3
3
  import type { AppClassProperties } from "../types";
4
4
  export interface ImageEditToolbarCallbacks {
5
5
  onQuickEdit?: () => void;
6
- onUpscale?: () => void;
7
6
  onRemoveBG?: () => void;
8
7
  onCrop?: () => void;
9
8
  onDownload?: () => void;
@@ -2,27 +2,41 @@ import "./ImageGeneratorPanel.scss";
2
2
  import type { ExcalidrawFrameLikeElement, NonDeletedExcalidrawElement } from "@orangecatai/element/types";
3
3
  import type { AppClassProperties } from "../types";
4
4
  export declare const MODEL_CONFIG: {
5
- readonly "Gemini 2.5 Flash": {
6
- readonly geminiModelId: "gemini-3.1-flash-image";
5
+ readonly "nano banana": {
6
+ readonly modelId: "google/gemini-2.5-flash-image";
7
+ readonly textOutput: true;
7
8
  readonly supportsImageSize: false;
8
- readonly supportsThinking: false;
9
9
  readonly supportedResolutions: readonly ["1K"];
10
10
  readonly supportedRatios: readonly ["21:9", "16:9", "4:3", "3:2", "1:1", "9:16", "3:4", "2:3", "5:4", "4:5"];
11
11
  };
12
- readonly "Gemini 3.1 Flash": {
13
- readonly geminiModelId: "gemini-3.1-flash-image";
12
+ readonly "nano banana 2": {
13
+ readonly modelId: "google/gemini-3.1-flash-image-preview";
14
+ readonly textOutput: true;
14
15
  readonly supportsImageSize: true;
15
- readonly supportsThinking: true;
16
16
  readonly supportedResolutions: readonly ["0.5K", "1K", "2K", "4K"];
17
17
  readonly supportedRatios: readonly ["21:9", "16:9", "4:3", "3:2", "1:1", "9:16", "3:4", "2:3", "5:4", "4:5", "4:1", "1:4", "8:1", "1:8"];
18
18
  };
19
- readonly "Gemini 3 Pro": {
20
- readonly geminiModelId: "gemini-3-pro-image";
19
+ readonly "nano banana pro": {
20
+ readonly modelId: "google/gemini-3-pro-image-preview";
21
+ readonly textOutput: true;
21
22
  readonly supportsImageSize: true;
22
- readonly supportsThinking: false;
23
23
  readonly supportedResolutions: readonly ["1K", "2K", "4K"];
24
24
  readonly supportedRatios: readonly ["21:9", "16:9", "4:3", "3:2", "1:1", "9:16", "3:4", "2:3", "5:4", "4:5"];
25
25
  };
26
+ readonly "seedream 4.5": {
27
+ readonly modelId: "bytedance-seed/seedream-4.5";
28
+ readonly textOutput: false;
29
+ readonly supportsImageSize: false;
30
+ readonly supportedResolutions: readonly ["1K"];
31
+ readonly supportedRatios: readonly ["16:9", "4:3", "3:2", "1:1", "9:16", "3:4", "2:3", "5:4", "4:5"];
32
+ };
33
+ readonly "grok image": {
34
+ readonly modelId: "x-ai/grok-imagine-image-quality";
35
+ readonly textOutput: false;
36
+ readonly supportsImageSize: true;
37
+ readonly supportedResolutions: readonly ["1K", "2K"];
38
+ readonly supportedRatios: readonly ["16:9", "4:3", "3:2", "1:1", "9:16", "3:4", "2:3", "5:4", "4:5"];
39
+ };
26
40
  };
27
41
  export type ModelName = keyof typeof MODEL_CONFIG;
28
42
  export declare const MODEL_NAMES: ModelName[];
@@ -31,7 +45,6 @@ export declare function getDimensions(model: ModelName, ratio: string, resolutio
31
45
  width: number;
32
46
  height: number;
33
47
  };
34
- export declare function callGeminiAPI(prompt: string, modelId: string, aspectRatio: string, resolution: Resolution, supportsImageSize: boolean, supportsThinking: boolean, apiKey: string, referenceImageDataUrl?: string, signal?: AbortSignal): Promise<string>;
35
48
  export declare const ImageGeneratorPanel: ({ element, app, onBeforeImageGen, onAfterImageGen, }: {
36
49
  element: NonDeletedExcalidrawElement & ExcalidrawFrameLikeElement;
37
50
  app: AppClassProperties;
@@ -0,0 +1,49 @@
1
+ import React from "react";
2
+ import "./StockImagePanel.scss";
3
+ import type { ExcalidrawImperativeAPI } from "../types";
4
+ export type StockImagePhoto = {
5
+ id: string;
6
+ thumbUrl: string;
7
+ regularUrl: string;
8
+ description: string | null;
9
+ authorName: string;
10
+ authorUsername: string;
11
+ };
12
+ export type StockImageSearchResult = {
13
+ photos: StockImagePhoto[];
14
+ totalPages: number;
15
+ };
16
+ export type LibraryImageFilter = "all" | "product" | "logo" | "lifestyle" | "auxiliary";
17
+ export type LibraryImage = {
18
+ id: string;
19
+ name: string;
20
+ url: string;
21
+ assetType: string;
22
+ };
23
+ export type LibraryImageResult = {
24
+ images: LibraryImage[];
25
+ totalPages: number;
26
+ };
27
+ export interface StockImagePanelProps {
28
+ isOpen: boolean;
29
+ onClose: () => void;
30
+ excalidrawAPI: ExcalidrawImperativeAPI | null;
31
+ onSearchStockImages?: (query: string, page: number) => Promise<StockImageSearchResult>;
32
+ onTriggerStockImageDownload?: (photoId: string) => Promise<void>;
33
+ onBeforeStockImageDownload?: () => Promise<{
34
+ allowed: boolean;
35
+ error?: string;
36
+ }>;
37
+ onAfterStockImageDownload?: () => void;
38
+ /**
39
+ * Fetch the signed-in user's own image library. Supplied by the host
40
+ * (the SDK never fetches on its own). Supports type filtering, name/tag
41
+ * search, and pagination ("Load more").
42
+ */
43
+ onFetchLibraryImages?: (params: {
44
+ filter: LibraryImageFilter;
45
+ query: string;
46
+ page: number;
47
+ }) => Promise<LibraryImageResult>;
48
+ }
49
+ export declare const StockImagePanel: React.FC<StockImagePanelProps>;
@@ -8,6 +8,12 @@ type ContentPart = {
8
8
  image_url: {
9
9
  url: string;
10
10
  };
11
+ } | {
12
+ type: "file";
13
+ file: {
14
+ filename: string;
15
+ file_data: string;
16
+ };
11
17
  };
12
18
  export type AgentMessage = {
13
19
  role: "system";
@@ -60,7 +66,7 @@ export type AgentResult = {
60
66
  export declare function buildBrandContextMessage(ctx: BrandContext): string;
61
67
  export type FileAttachment = {
62
68
  name: string;
63
- type: "image" | "text";
69
+ type: "image" | "text" | "pdf" | "docx";
64
70
  dataUrl?: string;
65
71
  textContent?: string;
66
72
  };
@@ -78,7 +84,7 @@ export declare function runAgentLoop(opts: {
78
84
  frameScreenshot?: string;
79
85
  fileAttachments?: FileAttachment[];
80
86
  webSearchEnabled?: boolean;
81
- apiKey: string;
87
+ chatUrl: string;
82
88
  chatModel?: string;
83
89
  agentImageModel?: string;
84
90
  toolCtx: ToolExecutionContext;
@@ -3,8 +3,3 @@
3
3
  * using the Web Audio API. Mistral Voxtral only accepts mp3 or wav.
4
4
  */
5
5
  export declare function blobToWavBase64(blob: Blob): Promise<string>;
6
- /**
7
- * Sends a base64-encoded audio string to the OpenRouter Voxtral model for
8
- * transcription. `format` must be "wav" or "mp3".
9
- */
10
- export declare function transcribeAudio(base64Audio: string, format: string, apiKey: string, voiceModel?: string): Promise<string>;
@@ -436,6 +436,18 @@ export declare const BANNER_TOOLS: readonly [{
436
436
  readonly additionalProperties: false;
437
437
  };
438
438
  };
439
+ }, {
440
+ readonly type: "function";
441
+ readonly function: {
442
+ readonly name: "list_frames";
443
+ readonly description: "List all frames currently on the canvas. Returns each frame's id, name, width, height, and child element count. Call this when you need to find a frameId and none was provided by the user.";
444
+ readonly parameters: {
445
+ readonly type: "object";
446
+ readonly properties: {};
447
+ readonly required: readonly [];
448
+ readonly additionalProperties: false;
449
+ };
450
+ };
439
451
  }, {
440
452
  readonly type: "function";
441
453
  readonly function: {
@@ -611,9 +623,10 @@ export declare function getFrameContext(api: ExcalidrawImperativeAPI, frameId: s
611
623
  } | null;
612
624
  export type ToolExecutionContext = {
613
625
  excalidrawAPI: ExcalidrawImperativeAPI;
614
- geminiApiKey: string;
626
+ /** Host proxy URL for the agent's generate_image tool. Key stays server-side. */
627
+ imageGenUrl: string;
615
628
  signal?: AbortSignal;
616
- /** Override Gemini model ID for the agent's generate_image tool. */
629
+ /** Override OpenRouter model ID for the agent's generate_image tool. */
617
630
  agentImageModel?: string;
618
631
  /**
619
632
  * Maps lowercase brand font-family names to their registered Excalidraw
@@ -56,8 +56,9 @@ export declare function runReviewerAgent(opts: {
56
56
  /** Original user request — first message only, not full conversation history */
57
57
  userBrief: string;
58
58
  brandContext?: BrandContext;
59
- apiKey: string;
60
- /** OpenRouter model tag. Must be vision-capable. Defaults to gemini-3.1-flash-lite-preview */
59
+ /** Host proxy URL for the reviewer's OpenRouter call. Key stays server-side. */
60
+ chatUrl: string;
61
+ /** OpenRouter model tag. Must be vision-capable. Defaults to minimax/minimax-m3 */
61
62
  reviewerModel?: string;
62
63
  signal?: AbortSignal;
63
64
  iteration: number;
@@ -1,7 +1,7 @@
1
1
  import "./AutoResizePanel.scss";
2
2
  import type { ExcalidrawFrameLikeElement, NonDeletedExcalidrawElement } from "@orangecatai/element/types";
3
3
  import type { AppClassProperties } from "../../types";
4
- export declare const AutoResizePanel: ({ element, app, onClose, onBeforeAutoResize, onAfterAutoResize, onRunningChange, openRouterApiKey, chatModel, agentImageModel, }: {
4
+ export declare const AutoResizePanel: ({ element, app, onClose, onBeforeAutoResize, onAfterAutoResize, onRunningChange, autoResizeUrl, chatModel, agentImageModel, }: {
5
5
  element: NonDeletedExcalidrawElement & ExcalidrawFrameLikeElement;
6
6
  app: AppClassProperties;
7
7
  onClose: () => void;
@@ -11,7 +11,7 @@ export declare const AutoResizePanel: ({ element, app, onClose, onBeforeAutoResi
11
11
  }>;
12
12
  onAfterAutoResize?: () => void;
13
13
  onRunningChange?: (running: boolean) => void;
14
- openRouterApiKey: string;
14
+ autoResizeUrl: string;
15
15
  chatModel: string;
16
16
  agentImageModel?: string;
17
17
  }) => import("react/jsx-runtime").JSX.Element;
@@ -126,8 +126,7 @@ export declare function runAutoResize(opts: {
126
126
  sourceFrameId: string;
127
127
  targetDimensions: TargetDimension[];
128
128
  app: AppClassProperties;
129
- geminiApiKey: string;
130
- openRouterApiKey: string;
129
+ autoResizeUrl: string;
131
130
  chatModel?: string;
132
131
  agentImageModel?: string;
133
132
  customFontMap?: Record<string, number>;
@@ -8,6 +8,8 @@ import "./css/styles.scss";
8
8
  import "./fonts/fonts.css";
9
9
  import "./css/tailwind.generated.css";
10
10
  import type { ExcalidrawProps } from "./types";
11
+ export { StockImagePanel } from "./components/StockImagePanel";
12
+ export type { StockImagePanelProps, StockImagePhoto, StockImageSearchResult, LibraryImage, LibraryImageResult, LibraryImageFilter, } from "./components/StockImagePanel";
11
13
  export declare const Excalidraw: React.MemoExoticComponent<(props: ExcalidrawProps) => import("react/jsx-runtime").JSX.Element>;
12
14
  export { getSceneVersion, hashElementsVersion, hashString, getNonDeletedElements, } from "@orangecatai/element";
13
15
  export { getTextFromElements } from "@orangecatai/element";
@@ -566,26 +566,22 @@ export interface ExcalidrawProps {
566
566
  showDeprecatedFonts?: boolean;
567
567
  renderScrollbars?: boolean;
568
568
  /**
569
- * Gemini API key for image generation.
570
- * When provided, takes precedence over the VITE_APP_GEMINI_API_KEY env variable.
571
- * Required for image generation when using this package as an npm dependency.
569
+ * Host proxy URL for OpenRouter image generation (ImageGeneratorPanel,
570
+ * ImageQuickEditPanel). The SDK POSTs the OpenRouter request body here; the
571
+ * host injects the API key and forwards. Keeps the provider key out of the
572
+ * browser.
572
573
  */
573
- geminiApiKey?: string;
574
+ imageGenUrl?: string;
574
575
  /**
575
- * Leonardo API key for image toolbar upscale action.
576
- * When provided, takes precedence over the VITE_APP_LEONARDO_API_KEY env variable.
576
+ * Host proxy URL for the auto-resize engine's OpenRouter calls (layout
577
+ * planning, vision tagging, HTML generation, reviewer). Key stays server-side.
577
578
  */
578
- leonardoApiKey?: string;
579
+ autoResizeUrl?: string;
579
580
  /**
580
- * OpenRouter API key for auto-resize layout planning.
581
- * When provided, takes precedence over the VITE_APP_OPEN_ROUTER_API_KEY env variable.
581
+ * Host proxy URL for the remove.bg toolbar action. The SDK POSTs
582
+ * `{ imageDataUrl }` and receives `{ imageDataUrl }`. Key stays server-side.
582
583
  */
583
- openRouterApiKey?: string;
584
- /**
585
- * remove.bg API key for the remove background toolbar action.
586
- * When provided, takes precedence over the VITE_APP_REMOVE_BG_API_KEY env variable.
587
- */
588
- removeBgApiKey?: string;
584
+ removeBgUrl?: string;
589
585
  /**
590
586
  * Called before any image generation (ImageGeneratorPanel, ImageQuickEditPanel,
591
587
  * or agent loop generate_image tool). Return `{ allowed: false }` to block.
@@ -599,16 +595,6 @@ export interface ExcalidrawProps {
599
595
  * Called after a successful image generation from any panel or agent tool.
600
596
  */
601
597
  onAfterImageGen?: () => void;
602
- /**
603
- * Called before an upscale is run (deduct credits, check quota).
604
- * Return `{ allowed: false, error: "..." }` to block the operation.
605
- */
606
- onBeforeUpscale?: () => Promise<{
607
- allowed: boolean;
608
- error?: string;
609
- }>;
610
- /** Called after a successful upscale. */
611
- onAfterUpscale?: () => void;
612
598
  /**
613
599
  * Called before a background removal is run (deduct credits, check quota).
614
600
  * Return `{ allowed: false, error: "..." }` to block the operation.
@@ -630,12 +616,12 @@ export interface ExcalidrawProps {
630
616
  /** Called after each successfully generated auto-resize dimension. */
631
617
  onAfterAutoResize?: () => void;
632
618
  /**
633
- * Gemini model ID used for AI image generation — covers both the auto-resize
619
+ * OpenRouter model ID used for AI image generation — covers both the auto-resize
634
620
  * background regeneration and the agent chat `generate_image` tool.
635
621
  * Pass the same value here and to `AIChatPanel.agentImageModel` to keep
636
622
  * both surfaces on the same model with a single configuration.
637
- * @default "gemini-3.1-flash-image-preview"
638
- * @example "gemini-3.1-flash-image-preview"
623
+ * @default "google/gemini-3.1-flash-image-preview"
624
+ * @example "google/gemini-2.5-flash-image"
639
625
  */
640
626
  agentImageModel?: string;
641
627
  /**
@@ -815,6 +801,10 @@ export type AppClassProperties = {
815
801
  onPointerDownEmitter: App["onPointerDownEmitter"];
816
802
  lastPointerMoveCoords: App["lastPointerMoveCoords"];
817
803
  bindModeHandler: App["bindModeHandler"];
804
+ refresh: App["refresh"];
805
+ refreshEditorInterface: App["refreshEditorInterface"];
806
+ lassoTrail: App["lassoTrail"];
807
+ toggleSidebar: App["toggleSidebar"];
818
808
  };
819
809
  export type PointerDownState = Readonly<{
820
810
  origin: Readonly<{
@@ -0,0 +1 @@
1
+ export declare function callOpenRouterImageAPI(prompt: string, modelId: string, aspectRatio: string, imageSize: string | null, textOutput: boolean, imageGenUrl: string, referenceImageDataUrl?: string, signal?: AbortSignal): Promise<string>;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@orangecatai/adgen-canvas",
3
- "version": "0.0.19",
3
+ "version": "0.0.21",
4
4
  "type": "module",
5
5
  "types": "./dist/types/excalidraw/index.d.ts",
6
6
  "main": "./dist/prod/index.js",
@@ -1 +0,0 @@
1
- import{T as a,U as b,V as c}from"../chunk-5GYFLSBF.js";import"../chunk-7XQHY7WT.js";import"../chunk-SRAX5OIU.js";export{c as decodePngMetadata,b as encodePngMetadata,a as getTEXtChunk};
@@ -1 +0,0 @@
1
- export declare function resolveGeminiApiKey(propKey?: string): string;
@@ -1 +0,0 @@
1
- export declare function resolveLeonardoApiKey(propKey?: string): string;