@fastlabai/design-editor 1.0.0-beta.1 → 1.0.0-beta.3

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.cts CHANGED
@@ -335,8 +335,8 @@ interface DesignEditorProps {
335
335
  sceneKey?: string;
336
336
  /** Called when the user clicks the back button in the toolbar. */
337
337
  onBack?: () => void;
338
- /** Called when the user exports the design. Receives the rendered Blob and the output format. */
339
- onExport?: (blob: Blob, format: 'png' | 'jpg' | 'svg') => void | Promise<void>;
338
+ /** Called when the user exports the design. Receives the rendered Blob, output format, and raw scene JSON. */
339
+ onExport?: (blob: Blob, format: 'png' | 'jpg' | 'svg', scene: IScene) => void | Promise<void>;
340
340
  /** Media library provider. Defaults to a null provider (empty Library panel). */
341
341
  mediaProvider?: MediaProvider;
342
342
  /** Font provider. Defaults to a Google Fonts provider. */
@@ -349,6 +349,8 @@ interface DesignEditorProps {
349
349
  className?: string;
350
350
  /** Custom render override for the Library panel — useful to inject host-app media UI. */
351
351
  libraryPanel?: LibraryPanelRenderProp;
352
+ /** Optional title to display in the toolbar. Defaults to "FastlabAI Design Studio". */
353
+ title?: React.ReactNode;
352
354
  }
353
355
  /**
354
356
  * The top-level image design editor. Renders a full-screen canvas-based editor
@@ -367,7 +369,7 @@ interface DesignEditorProps {
367
369
  * }
368
370
  * ```
369
371
  */
370
- declare function DesignEditor({ initialScene, sceneKey, onBack, onExport, mediaProvider, fontProvider, backgroundRemovalProvider, persistenceProvider, className, libraryPanel, }: DesignEditorProps): react_jsx_runtime.JSX.Element;
372
+ declare function DesignEditor({ initialScene, sceneKey, onBack, onExport, mediaProvider, fontProvider, backgroundRemovalProvider, persistenceProvider, className, libraryPanel, title, }: DesignEditorProps): react_jsx_runtime.JSX.Element;
371
373
 
372
374
  /**
373
375
  * @fastlabai/design-editor
@@ -379,6 +381,6 @@ declare function DesignEditor({ initialScene, sceneKey, onBack, onExport, mediaP
379
381
  * @packageDocumentation
380
382
  */
381
383
  /** Current package version. */
382
- declare const VERSION = "0.0.0";
384
+ declare const VERSION = "1.0.0-beta.3";
383
385
 
384
386
  export { type BackgroundRemovalProvider, DesignEditor, type DesignEditorProps, type FontDescriptor, type FontProvider, type ILayer, type IScene, type MediaItem, type MediaListResult, type MediaProvider, type PersistenceProvider, VERSION, createGoogleFontsProvider, createImglyBackgroundRemoval, createLocalStoragePersistence, createNullMediaProvider };
package/dist/index.d.ts CHANGED
@@ -335,8 +335,8 @@ interface DesignEditorProps {
335
335
  sceneKey?: string;
336
336
  /** Called when the user clicks the back button in the toolbar. */
337
337
  onBack?: () => void;
338
- /** Called when the user exports the design. Receives the rendered Blob and the output format. */
339
- onExport?: (blob: Blob, format: 'png' | 'jpg' | 'svg') => void | Promise<void>;
338
+ /** Called when the user exports the design. Receives the rendered Blob, output format, and raw scene JSON. */
339
+ onExport?: (blob: Blob, format: 'png' | 'jpg' | 'svg', scene: IScene) => void | Promise<void>;
340
340
  /** Media library provider. Defaults to a null provider (empty Library panel). */
341
341
  mediaProvider?: MediaProvider;
342
342
  /** Font provider. Defaults to a Google Fonts provider. */
@@ -349,6 +349,8 @@ interface DesignEditorProps {
349
349
  className?: string;
350
350
  /** Custom render override for the Library panel — useful to inject host-app media UI. */
351
351
  libraryPanel?: LibraryPanelRenderProp;
352
+ /** Optional title to display in the toolbar. Defaults to "FastlabAI Design Studio". */
353
+ title?: React.ReactNode;
352
354
  }
353
355
  /**
354
356
  * The top-level image design editor. Renders a full-screen canvas-based editor
@@ -367,7 +369,7 @@ interface DesignEditorProps {
367
369
  * }
368
370
  * ```
369
371
  */
370
- declare function DesignEditor({ initialScene, sceneKey, onBack, onExport, mediaProvider, fontProvider, backgroundRemovalProvider, persistenceProvider, className, libraryPanel, }: DesignEditorProps): react_jsx_runtime.JSX.Element;
372
+ declare function DesignEditor({ initialScene, sceneKey, onBack, onExport, mediaProvider, fontProvider, backgroundRemovalProvider, persistenceProvider, className, libraryPanel, title, }: DesignEditorProps): react_jsx_runtime.JSX.Element;
371
373
 
372
374
  /**
373
375
  * @fastlabai/design-editor
@@ -379,6 +381,6 @@ declare function DesignEditor({ initialScene, sceneKey, onBack, onExport, mediaP
379
381
  * @packageDocumentation
380
382
  */
381
383
  /** Current package version. */
382
- declare const VERSION = "0.0.0";
384
+ declare const VERSION = "1.0.0-beta.3";
383
385
 
384
386
  export { type BackgroundRemovalProvider, DesignEditor, type DesignEditorProps, type FontDescriptor, type FontProvider, type ILayer, type IScene, type MediaItem, type MediaListResult, type MediaProvider, type PersistenceProvider, VERSION, createGoogleFontsProvider, createImglyBackgroundRemoval, createLocalStoragePersistence, createNullMediaProvider };