@shotstack/shotstack-studio 2.25.0 → 2.26.1

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 CHANGED
@@ -633,6 +633,32 @@ declare type EditEventMap = {
633
633
 
634
634
  declare type EventPayloadMap<TPayload = any> = Record<string, TPayload>;
635
635
 
636
+ export declare interface ExportBlobOptions {
637
+ signal?: AbortSignal;
638
+ onProgress?: (fraction: number, stage: string) => void;
639
+ }
640
+
641
+ /**
642
+ * Export error with context
643
+ */
644
+ export declare class ExportError extends Error {
645
+ readonly phase: ExportPhase | (string & {});
646
+ readonly context: Record<string, unknown>;
647
+ readonly issues?: ExportIssue[] | undefined;
648
+ constructor(message: string, phase?: ExportPhase | (string & {}), context?: Record<string, unknown>, cause?: Error, issues?: ExportIssue[] | undefined);
649
+ }
650
+
651
+ export declare interface ExportIssue {
652
+ code: ExportIssueCode;
653
+ message: string;
654
+ clipId?: string;
655
+ }
656
+
657
+ export declare type ExportIssueCode = "ai-pending" | "output-format" | "video-source" | "chroma-key" | "filter" | "html" | "effect" | "transition" | "font" | "luma" | "too-long" | "browser";
658
+
659
+ /** Where an export stopped; `unknown` when an `ExportError` is built without one. */
660
+ export declare type ExportPhase = "init" | "assets" | "unsupported" | "export" | "cancelled" | "unknown";
661
+
636
662
  declare type GenerationModelCatalogueResponse = operations["getModels"]["responses"][200]["content"]["application/json"];
637
663
 
638
664
  declare type Listener<TPayload = any> = (payload: TPayload) => void;
@@ -958,21 +984,19 @@ export declare const VERSION: string;
958
984
 
959
985
  export declare class VideoExporter {
960
986
  private readonly edit;
961
- private readonly canvas;
962
987
  private readonly app;
963
- private isExporting;
964
988
  private videoProcessor;
965
989
  private audioProcessor;
966
990
  private progressUI;
967
- private exportCommand;
968
991
  constructor(edit: Edit, canvas: Canvas);
992
+ exportBlob(options?: ExportBlobOptions): Promise<Blob>;
969
993
  export(filename?: string, fps?: number): Promise<void>;
994
+ private encode;
995
+ private checkExportable;
970
996
  private processFrames;
971
997
  private handleKeyDown;
972
998
  dispose(): void;
973
999
  private prepareConfig;
974
- private saveEditState;
975
- private restoreEditState;
976
1000
  }
977
1001
 
978
1002
  /**