@animaapp/anima-sdk 0.6.21 → 0.6.23

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
@@ -146,6 +146,7 @@ export declare type CodegenSettings = BaseSettings & {
146
146
  enableDisplayDataId?: boolean;
147
147
  enableDisplayDataName?: boolean;
148
148
  url?: string;
149
+ prompt?: string;
149
150
  };
150
151
 
151
152
  /**
@@ -303,7 +304,9 @@ export declare type GetCodeFromFigmaErrorReason = "Selected node type is not sup
303
304
  export declare type GetCodeFromPromptErrorReason = "Invalid prompt" | "Generation failed" | "Unknown";
304
305
 
305
306
  export declare type GetCodeFromPromptHandler = ((message: SSEGetCodeFromPromptMessage) => void) | {
306
- onQueueing?: () => void;
307
+ onQueueing?: ({ sessionId }: {
308
+ sessionId: string;
309
+ }) => void;
307
310
  onStart?: ({ sessionId }: {
308
311
  sessionId: string;
309
312
  }) => void;
@@ -343,7 +346,9 @@ export declare type GetCodeFromPromptSettings = BaseSettings & {
343
346
  export declare type GetCodeFromWebsiteErrorReason = "Scraping is blocked" | "Unknown";
344
347
 
345
348
  export declare type GetCodeFromWebsiteHandler = ((message: SSEGetCodeFromWebsiteMessage) => void) | {
346
- onQueueing?: () => void;
349
+ onQueueing?: ({ sessionId }: {
350
+ sessionId: string;
351
+ }) => void;
347
352
  onStart?: ({ sessionId }: {
348
353
  sessionId: string;
349
354
  }) => void;
@@ -379,7 +384,9 @@ export declare type GetCodeFromWebsiteSettings = BaseSettings & {
379
384
  };
380
385
 
381
386
  export declare type GetCodeHandler = ((message: SSEGetCodeFromFigmaMessage) => void) | {
382
- onQueueing?: () => void;
387
+ onQueueing?: ({ sessionId }: {
388
+ sessionId: string;
389
+ }) => void;
383
390
  onStart?: ({ sessionId }: {
384
391
  sessionId: string;
385
392
  }) => void;
@@ -508,7 +515,7 @@ export declare type L2CParams = {
508
515
  input: L2CParamsInput;
509
516
  conventions: L2CParamsConvention;
510
517
  assetsStorage: L2CParamsAssetsStorage;
511
- viewports?: Array<'desktop' | 'tablet' | 'mobile'>;
518
+ viewports?: Array<"desktop" | "tablet" | "mobile">;
512
519
  };
513
520
 
514
521
  /**
@@ -520,9 +527,9 @@ export declare type L2CParamsAssetsStorage = L2CParamsBundledAssetsStorage;
520
527
  * @deprecated This type is deprecated and will be removed soon.
521
528
  */
522
529
  export declare type L2CParamsBundledAssetsStorage = {
523
- type: 'bundled';
530
+ type: "bundled";
524
531
  referencePath?: string;
525
- importMode?: 'watermarked' | 'original';
532
+ importMode?: "watermarked" | "original";
526
533
  };
527
534
 
528
535
  /**
@@ -533,13 +540,13 @@ export declare type L2CParamsConvention = L2CParamsHtmlConvention | L2CParamsRea
533
540
  /**
534
541
  * @deprecated This type is deprecated and will be removed soon.
535
542
  */
536
- export declare type L2CParamsFramework = 'html' | 'react';
543
+ export declare type L2CParamsFramework = "html" | "react";
537
544
 
538
545
  /**
539
546
  * @deprecated This type is deprecated and will be removed soon.
540
547
  */
541
548
  export declare type L2CParamsHtmlConvention = {
542
- framework: 'html';
549
+ framework: "html";
543
550
  styling: L2CParamsStyling;
544
551
  };
545
552
 
@@ -551,13 +558,13 @@ export declare type L2CParamsInput = L2CParamsUrlInput;
551
558
  /**
552
559
  * @deprecated This type is deprecated and will be removed soon.
553
560
  */
554
- export declare type L2CParamsLanguage = 'typescript';
561
+ export declare type L2CParamsLanguage = "typescript";
555
562
 
556
563
  /**
557
564
  * @deprecated This type is deprecated and will be removed soon.
558
565
  */
559
566
  export declare type L2CParamsReactConvention = {
560
- framework: 'react';
567
+ framework: "react";
561
568
  language: L2CParamsLanguage;
562
569
  styling: L2CParamsStyling;
563
570
  enableGeneratePackageLock?: boolean;
@@ -566,7 +573,7 @@ export declare type L2CParamsReactConvention = {
566
573
  /**
567
574
  * @deprecated This type is deprecated and will be removed soon.
568
575
  */
569
- export declare type L2CParamsStyling = 'tailwind' | 'inline-styles';
576
+ export declare type L2CParamsStyling = "tailwind" | "inline-styles";
570
577
 
571
578
  /**
572
579
  * @deprecated This type is deprecated and will be removed soon.
@@ -586,7 +593,8 @@ export declare class NotFound extends Error {
586
593
 
587
594
  export declare type ProgressMessage = {
588
595
  id: string;
589
- text: string;
596
+ title: string;
597
+ body: string;
590
598
  attachments?: {
591
599
  images?: string[];
592
600
  };
@@ -625,11 +633,19 @@ export declare type SSECodegenMessage = SSEGetCodeFromFigmaMessage;
625
633
 
626
634
  export declare type SSECommonMessage = {
627
635
  type: "queueing";
636
+ payload: {
637
+ sessionId: string;
638
+ };
628
639
  } | {
629
640
  type: "progress_messages_updated";
630
641
  payload: {
631
642
  progressMessages: ProgressMessage[];
632
643
  };
644
+ } | {
645
+ type: "job_status_updated";
646
+ payload: {
647
+ jobStatus: Record<string, any>;
648
+ };
633
649
  } | {
634
650
  type: "aborted";
635
651
  };