@umituz/react-native-ai-generation-content 1.83.44 → 1.83.45

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/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@umituz/react-native-ai-generation-content",
3
- "version": "1.83.44",
3
+ "version": "1.83.45",
4
4
  "description": "Provider-agnostic AI generation orchestration for React Native with result preview components",
5
5
  "main": "src/index.ts",
6
6
  "types": "src/index.ts",
@@ -120,7 +120,8 @@ export class VideoExecutor
120
120
  const rawResult = result as Record<string, unknown>;
121
121
  const data = (rawResult?.data ?? rawResult) as {
122
122
  video?: { url: string };
123
+ video_url?: string;
123
124
  };
124
- return data?.video?.url;
125
+ return data?.video?.url ?? data?.video_url;
125
126
  }
126
127
  }
@@ -75,8 +75,11 @@ export async function executeImageGeneration(
75
75
  enable_safety_checker: MODEL_INPUT_DEFAULTS.enableSafetyChecker,
76
76
  };
77
77
 
78
- // Add image_urls array for multi-person generation
79
- if (imageUrls.length > 0) {
78
+ // Single image: use image_url (singular) for edit-style models (e.g. xai/grok-imagine-image/edit)
79
+ // Multiple images: use image_urls (array) for multi-reference models
80
+ if (imageUrls.length === 1) {
81
+ modelInput.image_url = imageUrls[0];
82
+ } else if (imageUrls.length > 1) {
80
83
  modelInput.image_urls = imageUrls;
81
84
  }
82
85
 
@@ -235,7 +235,11 @@ export function useVideoQueueGeneration(props: UseVideoQueueGenerationProps): Us
235
235
  if (creationId && userId) {
236
236
  try {
237
237
  await persistence.updateToFailed(userId, creationId, error instanceof Error ? error.message : "Queue submission failed");
238
- } catch { /* best effort */ }
238
+ } catch (persistError) {
239
+ if (typeof __DEV__ !== "undefined" && __DEV__) {
240
+ console.error("[VideoQueue] Failed to persist submission error:", persistError);
241
+ }
242
+ }
239
243
  }
240
244
  isGeneratingRef.current = false;
241
245
  setIsGenerating(false);
@@ -247,7 +251,11 @@ export function useVideoQueueGeneration(props: UseVideoQueueGenerationProps): Us
247
251
  if (creationId && userId) {
248
252
  try {
249
253
  await persistence.updateToFailed(userId, creationId, queueResult.error || "Queue submission failed");
250
- } catch { /* best effort */ }
254
+ } catch (persistError) {
255
+ if (typeof __DEV__ !== "undefined" && __DEV__) {
256
+ console.error("[VideoQueue] Failed to persist queue failure:", persistError);
257
+ }
258
+ }
251
259
  }
252
260
  isGeneratingRef.current = false;
253
261
  setIsGenerating(false);
@@ -40,7 +40,7 @@ const DEFAULT_STATUS_LABELS: StatusLabels = {
40
40
  failed: "Failed",
41
41
  };
42
42
 
43
- export const PendingJobCard: React.FC<PendingJobCardProps<any, any>> = ({
43
+ export const PendingJobCard: React.FC<PendingJobCardProps> = ({
44
44
  job,
45
45
  onCancel,
46
46
  onRetry,