@umituz/react-native-ai-generation-content 1.37.34 → 1.37.35
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 +1 -1
- package/src/domains/generation/wizard/presentation/components/GenericWizardFlow.tsx +3 -0
- package/src/domains/generation/wizard/presentation/components/WizardFlowContent.tsx +3 -0
- package/src/domains/generation/wizard/presentation/components/WizardStepRenderer.tsx +2 -0
- package/src/domains/generation/wizard/presentation/components/WizardStepRenderer.types.ts +1 -0
- package/src/domains/generation/wizard/presentation/components/step-renderers/renderResultStep.tsx +3 -0
- package/src/domains/result-preview/presentation/components/ResultPreviewScreen.tsx +17 -14
- package/src/domains/result-preview/presentation/types/result-preview.types.ts +2 -0
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@umituz/react-native-ai-generation-content",
|
|
3
|
-
"version": "1.37.
|
|
3
|
+
"version": "1.37.35",
|
|
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",
|
|
@@ -25,6 +25,7 @@ export interface GenericWizardFlowProps {
|
|
|
25
25
|
readonly userId?: string;
|
|
26
26
|
readonly alertMessages: AlertMessages;
|
|
27
27
|
readonly skipResultStep?: boolean;
|
|
28
|
+
readonly hideActions?: boolean;
|
|
28
29
|
readonly onStepChange?: (stepId: string, stepType: StepType | string) => void;
|
|
29
30
|
readonly onGenerationStart?: (
|
|
30
31
|
data: Record<string, unknown>,
|
|
@@ -50,6 +51,7 @@ export const GenericWizardFlow: React.FC<GenericWizardFlowProps> = (props) => {
|
|
|
50
51
|
userId,
|
|
51
52
|
alertMessages,
|
|
52
53
|
skipResultStep = false,
|
|
54
|
+
hideActions = false,
|
|
53
55
|
onStepChange,
|
|
54
56
|
onGenerationStart,
|
|
55
57
|
onGenerationComplete,
|
|
@@ -105,6 +107,7 @@ export const GenericWizardFlow: React.FC<GenericWizardFlowProps> = (props) => {
|
|
|
105
107
|
userId={userId}
|
|
106
108
|
alertMessages={alertMessages}
|
|
107
109
|
skipResultStep={skipResultStep}
|
|
110
|
+
hideActions={hideActions}
|
|
108
111
|
onStepChange={onStepChange}
|
|
109
112
|
onGenerationStart={onGenerationStart}
|
|
110
113
|
onGenerationComplete={onGenerationComplete}
|
|
@@ -26,6 +26,7 @@ export interface WizardFlowContentProps {
|
|
|
26
26
|
readonly userId?: string;
|
|
27
27
|
readonly alertMessages: AlertMessages;
|
|
28
28
|
readonly skipResultStep?: boolean;
|
|
29
|
+
readonly hideActions?: boolean;
|
|
29
30
|
readonly onStepChange?: (stepId: string, stepType: StepType | string) => void;
|
|
30
31
|
readonly onGenerationStart?: (
|
|
31
32
|
data: Record<string, unknown>,
|
|
@@ -50,6 +51,7 @@ export const WizardFlowContent: React.FC<WizardFlowContentProps> = (props) => {
|
|
|
50
51
|
userId,
|
|
51
52
|
alertMessages,
|
|
52
53
|
skipResultStep = false,
|
|
54
|
+
hideActions = false,
|
|
53
55
|
onStepChange,
|
|
54
56
|
onGenerationStart,
|
|
55
57
|
onGenerationComplete,
|
|
@@ -150,6 +152,7 @@ export const WizardFlowContent: React.FC<WizardFlowContentProps> = (props) => {
|
|
|
150
152
|
isSaving={isSaving}
|
|
151
153
|
isSharing={isSharing}
|
|
152
154
|
showRating={Boolean(userId) && !hasRated}
|
|
155
|
+
hideActions={hideActions}
|
|
153
156
|
onNext={handlers.handleNextStep}
|
|
154
157
|
onBack={handlers.handleBack}
|
|
155
158
|
onPhotoContinue={handlers.handlePhotoContinue}
|
|
@@ -25,6 +25,7 @@ export const WizardStepRenderer: React.FC<WizardStepRendererProps> = ({
|
|
|
25
25
|
isSaving,
|
|
26
26
|
isSharing,
|
|
27
27
|
showRating = true,
|
|
28
|
+
hideActions = false,
|
|
28
29
|
onNext,
|
|
29
30
|
onBack,
|
|
30
31
|
onPhotoContinue,
|
|
@@ -75,6 +76,7 @@ export const WizardStepRenderer: React.FC<WizardStepRendererProps> = ({
|
|
|
75
76
|
iconOnly
|
|
76
77
|
showTryAgain
|
|
77
78
|
showRating={showRating}
|
|
79
|
+
hideActions={hideActions}
|
|
78
80
|
translations={{
|
|
79
81
|
title: t("generation.result.title"),
|
|
80
82
|
saveButton: t("generation.result.save"),
|
|
@@ -11,6 +11,7 @@ export interface WizardStepRendererProps {
|
|
|
11
11
|
readonly isSaving: boolean;
|
|
12
12
|
readonly isSharing: boolean;
|
|
13
13
|
readonly showRating?: boolean;
|
|
14
|
+
readonly hideActions?: boolean;
|
|
14
15
|
readonly onNext: () => void;
|
|
15
16
|
readonly onBack: () => void;
|
|
16
17
|
readonly onPhotoContinue: (stepId: string, image: UploadedImage) => void;
|
package/src/domains/generation/wizard/presentation/components/step-renderers/renderResultStep.tsx
CHANGED
|
@@ -11,6 +11,7 @@ export interface ResultStepProps {
|
|
|
11
11
|
readonly isSaving: boolean;
|
|
12
12
|
readonly isSharing: boolean;
|
|
13
13
|
readonly showRating: boolean;
|
|
14
|
+
readonly hideActions?: boolean;
|
|
14
15
|
readonly onDownload: () => void;
|
|
15
16
|
readonly onShare: () => void;
|
|
16
17
|
readonly onRate?: () => void;
|
|
@@ -25,6 +26,7 @@ export function renderResultStep({
|
|
|
25
26
|
isSaving,
|
|
26
27
|
isSharing,
|
|
27
28
|
showRating,
|
|
29
|
+
hideActions = false,
|
|
28
30
|
onDownload,
|
|
29
31
|
onShare,
|
|
30
32
|
onRate,
|
|
@@ -56,6 +58,7 @@ export function renderResultStep({
|
|
|
56
58
|
iconOnly
|
|
57
59
|
showTryAgain
|
|
58
60
|
showRating={showRating}
|
|
61
|
+
hideActions={hideActions}
|
|
59
62
|
translations={{
|
|
60
63
|
title: t("generation.result.title"),
|
|
61
64
|
saveButton: t("generation.result.save"),
|
|
@@ -32,6 +32,7 @@ export const ResultPreviewScreen: React.FC<ResultPreviewScreenProps> = ({
|
|
|
32
32
|
iconOnly = false,
|
|
33
33
|
showTryAgain = true,
|
|
34
34
|
showRating = false,
|
|
35
|
+
hideActions = false,
|
|
35
36
|
}) => {
|
|
36
37
|
const tokens = useAppDesignTokens();
|
|
37
38
|
const isVideo = Boolean(videoUrl);
|
|
@@ -66,20 +67,22 @@ export const ResultPreviewScreen: React.FC<ResultPreviewScreenProps> = ({
|
|
|
66
67
|
<View style={styles.resultContainer}>
|
|
67
68
|
{!hideLabel && <AtomicText style={styles.title}>{translations.yourResult}</AtomicText>}
|
|
68
69
|
{isVideo ? <VideoResultPlayer uri={displayMediaUrl} /> : <ResultImageCard imageUrl={displayMediaUrl} />}
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
|
|
70
|
+
{!hideActions && (
|
|
71
|
+
<ResultActionBar
|
|
72
|
+
isSaving={isSaving}
|
|
73
|
+
isSharing={isSharing}
|
|
74
|
+
onDownload={onDownload}
|
|
75
|
+
onShare={onShare}
|
|
76
|
+
onTryAgain={onTryAgain}
|
|
77
|
+
onRate={onRate}
|
|
78
|
+
saveButtonText={translations.saveButton}
|
|
79
|
+
shareButtonText={translations.shareButton}
|
|
80
|
+
tryAgainButtonText={translations.tryAnother}
|
|
81
|
+
iconOnly={iconOnly}
|
|
82
|
+
showTryAgain={showTryAgain}
|
|
83
|
+
showRating={showRating}
|
|
84
|
+
/>
|
|
85
|
+
)}
|
|
83
86
|
</View>
|
|
84
87
|
{showRecent && (
|
|
85
88
|
<RecentCreationsSection
|