@umituz/react-native-ai-generation-content 1.25.13 → 1.25.14

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.25.13",
3
+ "version": "1.25.14",
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",
@@ -75,6 +75,14 @@ export const GenericWizardFlow: React.FC<GenericWizardFlowProps> = ({
75
75
  initialStepIndex: 0,
76
76
  });
77
77
 
78
+ // Handle progress change - memoized to prevent infinite loops
79
+ const handleProgressChange = useCallback(
80
+ (progress: number) => {
81
+ flow.updateProgress(progress);
82
+ },
83
+ [flow],
84
+ );
85
+
78
86
  // Generation hook - handles AI generation automatically
79
87
  const generationHook = useWizardGeneration({
80
88
  scenario: scenario || { id: featureConfig.id, aiPrompt: "" },
@@ -84,9 +92,7 @@ export const GenericWizardFlow: React.FC<GenericWizardFlowProps> = ({
84
92
  alertMessages,
85
93
  onSuccess: onGenerationComplete,
86
94
  onError: onGenerationError,
87
- onProgressChange: (progress) => {
88
- flow.updateProgress(progress);
89
- },
95
+ onProgressChange: handleProgressChange,
90
96
  onCreditsExhausted,
91
97
  });
92
98