@umituz/react-native-ai-generation-content 1.90.23 → 1.90.24

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.
Files changed (40) hide show
  1. package/package.json +1 -1
  2. package/src/core/constants/index.ts +16 -0
  3. package/src/core/index.ts +68 -0
  4. package/src/domain/entities/index.ts +26 -0
  5. package/src/domain/interfaces/index.ts +20 -0
  6. package/src/domains/creations/index.ts +13 -0
  7. package/src/domains/generation/wizard/presentation/components/WizardFlowContent.tsx +2 -2
  8. package/src/domains/generation/wizard/presentation/screens/GenericPhotoUploadScreen.tsx +1 -1
  9. package/src/domains/image-to-video/domain/index.ts +5 -0
  10. package/src/domains/image-to-video/index.ts +11 -11
  11. package/src/domains/image-to-video/presentation/index.ts +4 -52
  12. package/src/domains/image-to-video/presentation/screens/index.ts +5 -0
  13. package/src/domains/shared/index.ts +6 -0
  14. package/src/domains/text-to-image/domain/index.ts +7 -0
  15. package/src/domains/text-to-image/domain-exports.ts +4 -4
  16. package/src/domains/text-to-image/index.ts +7 -0
  17. package/src/domains/text-to-image/presentation/index.ts +7 -0
  18. package/src/domains/text-to-image/presentation/screens/index.ts +5 -0
  19. package/src/domains/text-to-image/presentation-exports.ts +4 -4
  20. package/src/domains/text-to-video/domain/index.ts +5 -0
  21. package/src/domains/text-to-video/index.ts +5 -5
  22. package/src/domains/text-to-video/presentation/index.ts +4 -30
  23. package/src/domains/text-to-video/presentation/screens/index.ts +5 -0
  24. package/src/exports/features.ts +2 -2
  25. package/src/exports/presentation.ts +2 -2
  26. package/src/index.ts +1 -1
  27. package/src/infrastructure/constants/index.ts +9 -0
  28. package/src/infrastructure/services/generation-orchestrator.service.ts +1 -1
  29. package/src/infrastructure/utils/index.ts +24 -0
  30. package/src/presentation/components/headers/index.ts +3 -0
  31. package/src/presentation/components/index.ts +16 -0
  32. package/src/presentation/components/selectors/factories/index.ts +8 -0
  33. package/src/presentation/components/selectors/index.ts +21 -0
  34. package/src/shared/components/index.ts +5 -0
  35. package/src/shared/hooks/index.ts +6 -0
  36. package/src/shared/index.ts +9 -0
  37. package/src/shared/utils/calculations/index.ts +46 -0
  38. package/src/shared/utils/date/index.ts +7 -0
  39. package/src/shared-kernel/index.ts +7 -0
  40. package/src/shared-kernel/infrastructure/validation/index.ts +36 -0
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@umituz/react-native-ai-generation-content",
3
- "version": "1.90.23",
3
+ "version": "1.90.24",
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",
@@ -0,0 +1,16 @@
1
+ /**
2
+ * AI Generation Constants
3
+ *
4
+ * Generic, provider-agnostic constants — single source of truth for all apps.
5
+ * Model IDs and pricing are NOT here: those are always app-level decisions.
6
+ */
7
+
8
+ export * from "./video.constants";
9
+ export * from "./aspect-ratio.constants";
10
+ export * from "./image.constants";
11
+ export * from "./animation.constants";
12
+ export * from "./validation.constants";
13
+ export * from "./preset-styles.constants";
14
+ export * from "./style-options.constants";
15
+ export * from "./duration-options.constants";
16
+ export * from "./script-durations.constants";
@@ -0,0 +1,68 @@
1
+ /**
2
+ * @umituz/react-native-ai-generation-content/core
3
+ *
4
+ * Core types for AI generation providers.
5
+ * This module contains ONLY types and utilities - no implementation details.
6
+ *
7
+ * Use this subpath for provider implementations:
8
+ * ```typescript
9
+ * import type { IAIProvider, AIProviderConfig } from "@umituz/react-native-ai-generation-content/core";
10
+ * ```
11
+ *
12
+ * @module @umituz/react-native-ai-generation-content/core
13
+ */
14
+
15
+ // Result Pattern
16
+ export type { Result, Success, Failure } from "../domain/types/result.types";
17
+ export {
18
+ success,
19
+ failure,
20
+ isSuccess,
21
+ isFailure,
22
+ mapResult,
23
+ andThen,
24
+ unwrap,
25
+ unwrapOr,
26
+ } from "../domain/types/result.types";
27
+
28
+ // Error Types
29
+ export { AIErrorType } from "../domain/entities/error.types";
30
+ export type { AIErrorInfo, AIErrorMessages } from "../domain/entities/error.types";
31
+
32
+ // Provider Types
33
+ export type {
34
+ // Feature Types
35
+ ImageFeatureType,
36
+ VideoFeatureType,
37
+ // Config
38
+ AIProviderConfig,
39
+ // Status
40
+ AIJobStatusType,
41
+ AILogEntry,
42
+ JobSubmission,
43
+ JobStatus,
44
+ // Progress
45
+ ProviderProgressInfo,
46
+ SubscribeOptions,
47
+ RunOptions,
48
+ // Capabilities
49
+ ProviderCapabilities,
50
+ // Input Data
51
+ ImageFeatureInputData,
52
+ VideoFeatureInputData,
53
+ // Main Provider Interface
54
+ IAIProvider,
55
+ // Logging
56
+ ProviderLogEntry,
57
+ } from "../domain/interfaces/ai-provider.interface";
58
+
59
+ // Generation Constants
60
+ export * from "./constants";
61
+
62
+ // Segregated provider sub-interfaces
63
+ export type { IAIProviderLifecycle } from "../domain/interfaces/provider-lifecycle.interface";
64
+ export type { IAIProviderCapabilities } from "../domain/interfaces/provider-capabilities.interface";
65
+ export type { IAIProviderJobManager } from "../domains/background/domain/interfaces/provider-job-manager.interface";
66
+ export type { IAIProviderExecutor } from "../domain/interfaces/provider-executor.interface";
67
+ export type { IAIProviderImageFeatures } from "../domain/interfaces/provider-image-features.interface";
68
+ export type { IAIProviderVideoFeatures } from "../domain/interfaces/provider-video-features.interface";
@@ -0,0 +1,26 @@
1
+ /**
2
+ * Domain Entities
3
+ */
4
+
5
+ export * from "./error.types";
6
+ export * from "./polling.types";
7
+ export * from "./generation.types";
8
+ export * from "./processing-modes.types";
9
+ export * from "./flow-configuration.types";
10
+ export * from "./flow-config-data.types";
11
+ export * from "./flow-step.types";
12
+ export * from "./flow-config.types";
13
+ export * from "./flow-state.types";
14
+ export * from "./flow-actions.types";
15
+
16
+ // Re-export background job types
17
+ export type {
18
+ BackgroundJobStatus,
19
+ BackgroundJob,
20
+ AddJobInput,
21
+ UpdateJobInput,
22
+ JobExecutorConfig,
23
+ GenerationMode,
24
+ BackgroundQueueConfig,
25
+ } from "../../domains/background/domain/entities/job.types";
26
+ export { DEFAULT_QUEUE_CONFIG } from "../../domains/background/domain/entities/job.types";
@@ -0,0 +1,20 @@
1
+ /**
2
+ * Domain Interfaces
3
+ */
4
+
5
+ export * from "./ai-provider.interface";
6
+ export * from "./ai-provider-config.types";
7
+ export * from "./ai-provider-progress.types";
8
+ export * from "./ai-provider-status.types";
9
+ export * from "./video-model-config.types";
10
+ export * from "./provider-lifecycle.interface";
11
+ export * from "./provider-capabilities.interface";
12
+ export * from "./provider-executor.interface";
13
+ export * from "./provider-image-features.interface";
14
+ export * from "./provider-video-features.interface";
15
+
16
+ // App Services
17
+ export * from "./app-services.interface";
18
+ export * from "./app-services-auth.interface";
19
+ export * from "./app-services-optional.interface";
20
+ export * from "./app-services-composite.interface";
@@ -0,0 +1,13 @@
1
+ /**
2
+ * Creations Domain
3
+ * AI-generated creations gallery with filtering, sharing, and management
4
+ */
5
+
6
+ // Domain Layer
7
+ export * from "./domain-exports";
8
+
9
+ // Infrastructure Layer
10
+ export * from "./infrastructure-exports";
11
+
12
+ // Presentation Layer
13
+ export * from "./presentation-exports";
@@ -12,8 +12,8 @@ import type { WizardFeatureConfig } from "../../domain/entities/wizard-feature.t
12
12
  import { buildFlowStepsFromWizard } from "../../infrastructure/builders/dynamic-step-builder";
13
13
  import { useWizardGeneration, type WizardScenarioData } from "../hooks/useWizardGeneration";
14
14
  import type { AlertMessages } from "../../../../../presentation/hooks/generation/types";
15
- import type { Creation } from "../../../../creations/domain/entities/Creation";
16
- import { createCreationsRepository } from "../../../../creations";
15
+ import type { Creation } from "../../../../creations/domain/entities/index";
16
+ import { createCreationsRepository } from "../../../../creations/index";
17
17
  import { useResultActions } from "../../../../result-preview/presentation/hooks/useResultActions";
18
18
  import { useWizardFlowHandlers } from "../hooks/useWizardFlowHandlers";
19
19
  import { extractDuration, extractResolution, getConfigDefaultDuration, getConfigDefaultResolution } from "../../infrastructure/utils/credit-value-extractors";
@@ -10,7 +10,7 @@ import { ScreenLayout } from "@umituz/react-native-design-system/layouts";
10
10
  import { useAlert, AlertType, AlertMode, NavigationHeader, InfoGrid } from "@umituz/react-native-design-system/molecules";
11
11
  import type { InfoGridItem } from "@umituz/react-native-design-system/molecules";
12
12
  import { useAppDesignTokens, type DesignTokens } from "@umituz/react-native-design-system/theme";
13
- import { PhotoUploadCard } from "../../../../../presentation/components";
13
+ import { PhotoUploadCard } from "../../../../../presentation/components/index";
14
14
  import type { UploadedImage } from "../../../../../presentation/hooks/generation/useAIGenerateState";
15
15
  import { usePhotoUploadState, type PhotoUploadError } from "../hooks/usePhotoUploadState";
16
16
  import { WizardContinueButton } from "../components/WizardContinueButton";
@@ -0,0 +1,5 @@
1
+ /**
2
+ * Image to Video Domain
3
+ */
4
+
5
+ export * from "./types";
@@ -8,24 +8,24 @@
8
8
  // =============================================================================
9
9
 
10
10
  // Animation Types
11
- export type { AnimationStyle, AnimationStyleId } from "./domain";
11
+ export type { AnimationStyle, AnimationStyleId } from "./domain/index";
12
12
 
13
13
  // Duration Types
14
- export type { VideoDuration, DurationOption } from "./domain";
14
+ export type { VideoDuration, DurationOption } from "./domain/index";
15
15
 
16
16
  // Form Types
17
17
  export type {
18
18
  ImageToVideoFormState,
19
19
  ImageToVideoFormActions,
20
20
  ImageToVideoFormDefaults,
21
- } from "./domain";
21
+ } from "./domain/index";
22
22
 
23
23
  // Config Types
24
24
  export type {
25
25
  ImageToVideoCallbacks,
26
26
  ImageToVideoFormConfig,
27
27
  ImageToVideoTranslationsExtended,
28
- } from "./domain";
28
+ } from "./domain/index";
29
29
 
30
30
  // Core Feature Types
31
31
  export type {
@@ -42,7 +42,7 @@ export type {
42
42
  ImageToVideoGenerationStartData,
43
43
  ImageToVideoCreationData,
44
44
  ImageToVideoFeatureConfig,
45
- } from "./domain";
45
+ } from "./domain/index";
46
46
 
47
47
  // =============================================================================
48
48
  // INFRASTRUCTURE LAYER
@@ -59,7 +59,7 @@ export {
59
59
  useImageToVideoFormState,
60
60
  useImageToVideoGeneration,
61
61
  useImageToVideoForm,
62
- } from "./presentation";
62
+ } from "./presentation/index";
63
63
  export type {
64
64
  UseImageToVideoFormStateOptions,
65
65
  UseImageToVideoFormStateReturn,
@@ -67,14 +67,14 @@ export type {
67
67
  UseImageToVideoGenerationReturn,
68
68
  UseImageToVideoFormOptions,
69
69
  UseImageToVideoFormReturn,
70
- } from "./presentation";
70
+ } from "./presentation/index";
71
71
 
72
72
  // Provider-based Feature Hook
73
- export { useImageToVideoFeature } from "./presentation";
73
+ export { useImageToVideoFeature } from "./presentation/index";
74
74
  export type {
75
75
  UseImageToVideoFeatureProps,
76
76
  UseImageToVideoFeatureReturn,
77
- } from "./presentation";
77
+ } from "./presentation/index";
78
78
 
79
79
  // =============================================================================
80
80
  // PRESENTATION LAYER - Components
@@ -85,7 +85,7 @@ export {
85
85
  ImageToVideoDurationSelector,
86
86
  ImageToVideoSelectionGrid,
87
87
  ImageToVideoGenerateButton,
88
- } from "./presentation";
88
+ } from "./presentation/index";
89
89
 
90
90
  export type {
91
91
  ImageToVideoAnimationStyleSelectorProps,
@@ -93,4 +93,4 @@ export type {
93
93
  ImageToVideoSelectionGridProps,
94
94
  ImageToVideoSelectionGridTranslations,
95
95
  ImageToVideoGenerateButtonProps,
96
- } from "./presentation";
96
+ } from "./presentation/index";
@@ -1,55 +1,7 @@
1
1
  /**
2
- * Image-to-Video Presentation Index
3
- * Exports all presentation layer items (hooks and components)
2
+ * Image to Video Presentation
4
3
  */
5
4
 
6
- // =============================================================================
7
- // HOOKS
8
- // =============================================================================
9
-
10
- // Form State Hook
11
- export { useImageToVideoFormState } from "./hooks";
12
- export type {
13
- UseImageToVideoFormStateOptions,
14
- UseImageToVideoFormStateReturn,
15
- } from "./hooks";
16
-
17
- // Generation Hook
18
- export { useImageToVideoGeneration } from "./hooks";
19
- export type {
20
- UseImageToVideoGenerationOptions,
21
- UseImageToVideoGenerationReturn,
22
- } from "./hooks";
23
-
24
- // Combined Form Hook
25
- export { useImageToVideoForm } from "./hooks";
26
- export type {
27
- UseImageToVideoFormOptions,
28
- UseImageToVideoFormReturn,
29
- } from "./hooks";
30
-
31
- // Provider-based Feature Hook
32
- export { useImageToVideoFeature } from "./hooks";
33
- export type {
34
- UseImageToVideoFeatureProps,
35
- UseImageToVideoFeatureReturn,
36
- } from "./hooks";
37
-
38
- // =============================================================================
39
- // COMPONENTS
40
- // =============================================================================
41
-
42
- export {
43
- ImageToVideoAnimationStyleSelector,
44
- ImageToVideoDurationSelector,
45
- ImageToVideoSelectionGrid,
46
- ImageToVideoGenerateButton,
47
- } from "./components";
48
-
49
- export type {
50
- ImageToVideoAnimationStyleSelectorProps,
51
- ImageToVideoDurationSelectorProps,
52
- ImageToVideoSelectionGridProps,
53
- ImageToVideoSelectionGridTranslations,
54
- ImageToVideoGenerateButtonProps,
55
- } from "./components";
5
+ export * from "./components";
6
+ export * from "./hooks";
7
+ export * from "./screens";
@@ -0,0 +1,5 @@
1
+ /**
2
+ * Image to Video Screens
3
+ */
4
+
5
+ export * from "./ImageToVideoWizardFlow";
@@ -0,0 +1,6 @@
1
+ /**
2
+ * Shared Features
3
+ */
4
+
5
+ export * from "./presentation/utils";
6
+ export * from "./presentation/components";
@@ -0,0 +1,7 @@
1
+ /**
2
+ * Text to Image Domain
3
+ */
4
+
5
+ export * from "./constants";
6
+ export * from "./types";
7
+ export * from "./utils";
@@ -12,7 +12,7 @@ export type {
12
12
  TextToImageFormState,
13
13
  TextToImageFormActions,
14
14
  TextToImageFormDefaults,
15
- } from "./domain";
15
+ } from "./domain/index";
16
16
 
17
17
  // Config Types
18
18
  export type {
@@ -23,7 +23,7 @@ export type {
23
23
  TextToImageCallbacks,
24
24
  TextToImageFormConfig,
25
25
  TextToImageTranslations,
26
- } from "./domain";
26
+ } from "./domain/index";
27
27
 
28
28
  // Provider Types
29
29
  export type {
@@ -34,7 +34,7 @@ export type {
34
34
  TextToImageInputBuilder,
35
35
  TextToImageResultExtractor,
36
36
  TextToImageFeatureConfig,
37
- } from "./domain";
37
+ } from "./domain/index";
38
38
 
39
39
  // Constants
40
40
  export {
@@ -47,4 +47,4 @@ export {
47
47
  DEFAULT_TEXT_TO_IMAGE_PROMPTS,
48
48
  DEFAULT_TEXT_TO_VOICE_PROMPTS,
49
49
  type PromptSuggestion,
50
- } from "./domain";
50
+ } from "./domain/index";
@@ -0,0 +1,7 @@
1
+ /**
2
+ * Text to Image Feature
3
+ */
4
+
5
+ export * from "./domain";
6
+ export * from "./infrastructure-exports";
7
+ export * from "./presentation-exports";
@@ -0,0 +1,7 @@
1
+ /**
2
+ * Text to Image Presentation
3
+ */
4
+
5
+ export * from "./components";
6
+ export * from "./hooks";
7
+ export * from "./screens";
@@ -0,0 +1,5 @@
1
+ /**
2
+ * Text to Image Screens
3
+ */
4
+
5
+ export * from "./TextToImageWizardFlow";
@@ -7,7 +7,7 @@ export {
7
7
  useFormState,
8
8
  useGeneration,
9
9
  useTextToImageForm,
10
- } from "./presentation";
10
+ } from "./presentation/index";
11
11
  export type {
12
12
  UseFormStateOptions,
13
13
  UseFormStateReturn,
@@ -16,7 +16,7 @@ export type {
16
16
  UseGenerationReturn,
17
17
  UseTextToImageFormOptions,
18
18
  UseTextToImageFormReturn,
19
- } from "./presentation";
19
+ } from "./presentation/index";
20
20
 
21
21
  // Components
22
22
  export {
@@ -29,7 +29,7 @@ export {
29
29
  TextToImageOutputFormatSelector,
30
30
  TextToImageGenerateButton,
31
31
  TextToImageSettingsSheet,
32
- } from "./presentation";
32
+ } from "./presentation/index";
33
33
 
34
34
  export type {
35
35
  TextToImagePromptInputProps,
@@ -38,4 +38,4 @@ export type {
38
38
  TextToImageAspectRatioSelectorProps,
39
39
  TextToImageGenerateButtonProps,
40
40
  TextToImageSettingsSheetProps,
41
- } from "./presentation";
41
+ } from "./presentation/index";
@@ -0,0 +1,5 @@
1
+ /**
2
+ * Text to Video Domain
3
+ */
4
+
5
+ export * from "./types";
@@ -36,9 +36,9 @@ export type {
36
36
  HintItem,
37
37
  ExamplePromptsProps,
38
38
  ExamplePrompt,
39
- } from "./domain";
39
+ } from "./domain/index";
40
40
 
41
- export { INITIAL_FORM_STATE, INITIAL_GENERATION_STATE } from "./domain";
41
+ export { INITIAL_FORM_STATE, INITIAL_GENERATION_STATE } from "./domain/index";
42
42
 
43
43
  // Infrastructure Services
44
44
  export { executeTextToVideo, hasTextToVideoSupport } from "./infrastructure/services";
@@ -48,7 +48,7 @@ export type { ExecuteTextToVideoOptions } from "./infrastructure/services";
48
48
  export {
49
49
  useTextToVideoFeature,
50
50
  useTextToVideoForm,
51
- } from "./presentation";
51
+ } from "./presentation/index";
52
52
 
53
53
  export type {
54
54
  UseTextToVideoFeatureProps,
@@ -56,7 +56,7 @@ export type {
56
56
  TextToVideoGenerateParams,
57
57
  UseTextToVideoFormProps,
58
58
  UseTextToVideoFormReturn,
59
- } from "./presentation";
59
+ } from "./presentation/index";
60
60
 
61
61
  // Presentation Components
62
62
  export {
@@ -65,4 +65,4 @@ export {
65
65
  OptionsPanel,
66
66
  HeroSection,
67
67
  HintCarousel,
68
- } from "./presentation";
68
+ } from "./presentation/index";
@@ -1,33 +1,7 @@
1
1
  /**
2
- * Text-to-Video Presentation Index
3
- * Exports all presentation layer items (hooks and components)
2
+ * Text to Video Presentation
4
3
  */
5
4
 
6
- // =============================================================================
7
- // HOOKS
8
- // =============================================================================
9
-
10
- export { useTextToVideoFeature } from "./hooks";
11
- export type {
12
- UseTextToVideoFeatureProps,
13
- UseTextToVideoFeatureReturn,
14
- TextToVideoGenerateParams,
15
- } from "./hooks";
16
-
17
- export { useTextToVideoForm } from "./hooks";
18
- export type {
19
- UseTextToVideoFormProps,
20
- UseTextToVideoFormReturn,
21
- } from "./hooks";
22
-
23
- // =============================================================================
24
- // COMPONENTS
25
- // =============================================================================
26
-
27
- export {
28
- GenerationTabs,
29
- FrameSelector,
30
- OptionsPanel,
31
- HeroSection,
32
- HintCarousel,
33
- } from "./components";
5
+ export * from "./components";
6
+ export * from "./hooks";
7
+ export * from "./screens";
@@ -0,0 +1,5 @@
1
+ /**
2
+ * Text to Video Screens
3
+ */
4
+
5
+ export * from "./TextToVideoWizardFlow";
@@ -18,7 +18,7 @@ export type {
18
18
  UseTextToImageFormOptions, UseTextToImageFormReturn,
19
19
  TextToImagePromptInputProps, TextToImageExamplePromptsProps, TextToImageStyleSelectorProps,
20
20
  TextToImageAspectRatioSelectorProps, TextToImageGenerateButtonProps, TextToImageSettingsSheetProps,
21
- } from "../domains/text-to-image";
21
+ } from "../domains/text-to-image/index";
22
22
  export {
23
23
  DEFAULT_IMAGE_STYLES, DEFAULT_NUM_IMAGES_OPTIONS, ASPECT_RATIO_VALUES, IMAGE_SIZE_VALUES,
24
24
  OUTPUT_FORMAT_VALUES, DEFAULT_FORM_VALUES, DEFAULT_TEXT_TO_IMAGE_PROMPTS, DEFAULT_TEXT_TO_VOICE_PROMPTS,
@@ -29,7 +29,7 @@ export {
29
29
  TextToImagePromptInput, TextToImageExamplePrompts, TextToImageNumImagesSelector,
30
30
  TextToImageStyleSelector, TextToImageAspectRatioSelector, TextToImageSizeSelector,
31
31
  TextToImageOutputFormatSelector, TextToImageGenerateButton, TextToImageSettingsSheet,
32
- } from "../domains/text-to-image";
32
+ } from "../domains/text-to-image/index";
33
33
 
34
34
  // Text-to-Video Feature
35
35
  export type {
@@ -41,7 +41,7 @@ export {
41
41
  AIGenerationConfig, ModelSelector, SuccessRedirectionCard,
42
42
  createAspectRatioOptions, createDurationOptions, createStyleOptions, createStyleOptionsFromConfig,
43
43
  ASPECT_RATIO_IDS, COMMON_DURATIONS,
44
- } from "../presentation/components";
44
+ } from "../presentation/components/index";
45
45
  export type {
46
46
  GenerationProgressContentProps, PendingJobCardProps, StatusLabels,
47
47
  PendingJobCardActionsProps, GenerationResultData, GenerationResultContentProps,
@@ -56,7 +56,7 @@ export type {
56
56
  StyleOption, AspectRatioOption, DurationValue, AspectRatioTranslations, DurationOption,
57
57
  StyleTranslations, AIGenerationFormProps, AIGenerationFormTranslations,
58
58
  AIGenerationConfigProps, ModelOption, ModelSelectorProps, SuccessRedirectionCardProps,
59
- } from "../presentation/components";
59
+ } from "../presentation/components/index";
60
60
 
61
61
  // Layouts
62
62
  export {
package/src/index.ts CHANGED
@@ -12,7 +12,7 @@ export * from "./exports/features";
12
12
  export * from "./shared";
13
13
 
14
14
  // Creations Domain
15
- export * from "./domains/creations";
15
+ export * from "./domains/creations/index";
16
16
 
17
17
  // Scenarios Domain
18
18
  export * from "./domains/scenarios";
@@ -0,0 +1,9 @@
1
+ /**
2
+ * Infrastructure Constants
3
+ */
4
+
5
+ // Polling Constants
6
+ export * from "./polling.constants";
7
+
8
+ // Validation Constants
9
+ export * from "./validation.constants";
@@ -12,7 +12,7 @@ import type {
12
12
  import { classifyError } from "../utils/error-classification";
13
13
  import { pollJob } from "../../domains/background/infrastructure/services/job-poller-index";
14
14
  import { ProviderValidator } from "./provider-validator";
15
- import { calculateDurationMs } from "../../shared/utils/calculations";
15
+ import { calculateDurationMs } from "../../shared/utils/calculations/time-calculations";
16
16
 
17
17
 
18
18
  export interface OrchestratorConfig {
@@ -0,0 +1,24 @@
1
+ /**
2
+ * Infrastructure Utils
3
+ */
4
+
5
+ export * from "./error-classification";
6
+ export * from "./error-factory";
7
+ export * from "./message-extractor";
8
+ export * from "./classifier-helpers";
9
+ export * from "./result-polling";
10
+ export * from "../../domains/background/infrastructure/utils/polling-interval.util";
11
+ export * from "./progress-calculator.util";
12
+ export * from "./progress.utils";
13
+ export * from "../../domains/background/infrastructure/utils/status-checker.util";
14
+ export * from "../../domains/background/infrastructure/utils/result-validator.util";
15
+ export * from "./url-extractor.util";
16
+ export * from "./photo-generation";
17
+ export * from "./feature-utils";
18
+ export * from "./video-helpers";
19
+ export * from "./provider-validator.util";
20
+ export * from "./base64.util";
21
+ export * from "./video-result-extractor.util";
22
+ export * from "./id-generator.util";
23
+ export * from "./intensity.util";
24
+ export * from "./couple-input.util";
@@ -0,0 +1,3 @@
1
+ export * from "./FeatureHeader";
2
+ export * from "./AIGenScreenHeader";
3
+ export * from "./CreditBadge";
@@ -0,0 +1,16 @@
1
+ /**
2
+ * Presentation Components
3
+ * Main UI components for AI generation
4
+ */
5
+
6
+ export * from "./AIGenerationForm";
7
+ export * from "./buttons";
8
+ export * from "./display";
9
+ export * from "./headers";
10
+ export * from "./image-picker";
11
+ export * from "./modals";
12
+ export * from "./PhotoUploadCard";
13
+ export * from "./prompts";
14
+ export * from "./selectors";
15
+ export * from "./shared";
16
+ export * from "./result";
@@ -0,0 +1,8 @@
1
+ /**
2
+ * Selector Factories
3
+ * i18n-ready factory functions for selector options
4
+ */
5
+
6
+ export * from "./aspect-ratio.factory";
7
+ export * from "./duration.factory";
8
+ export * from "./style.factory";
@@ -0,0 +1,21 @@
1
+ /**
2
+ * Selector Components
3
+ * Generic, props-driven selection UI components
4
+ */
5
+
6
+ export { StyleSelector } from "./StyleSelector";
7
+ export { AspectRatioSelector } from "./AspectRatioSelector";
8
+ export { DurationSelector } from "./DurationSelector";
9
+ export { GridSelector, type GridSelectorProps, type GridSelectorOption } from "./GridSelector";
10
+
11
+ export type { StyleSelectorProps } from "./StyleSelector";
12
+ export type { AspectRatioSelectorProps } from "./AspectRatioSelector";
13
+ export type { DurationSelectorProps } from "./DurationSelector";
14
+
15
+ export type {
16
+ StyleOption,
17
+ AspectRatioOption,
18
+ DurationValue,
19
+ } from "./types";
20
+
21
+ export * from "./factories";
@@ -0,0 +1,5 @@
1
+ /**
2
+ * Shared Components
3
+ */
4
+
5
+ export * from "./common";
@@ -0,0 +1,6 @@
1
+ /**
2
+ * Shared Hooks
3
+ */
4
+
5
+ export * from "./factories";
6
+ export * from "./useStableCallback";
@@ -0,0 +1,9 @@
1
+ /**
2
+ * Shared Utilities and Components
3
+ */
4
+
5
+ export * from "./utils/date";
6
+ export * from "./utils/calculations";
7
+ export * from "./utils/filters";
8
+ export * from "./hooks";
9
+ export * from "./components";
@@ -0,0 +1,46 @@
1
+ /**
2
+ * Calculation Utilities
3
+ * Centralized calculation operations for better performance and maintainability
4
+ */
5
+
6
+ // Credit & Cost Calculations
7
+ export {
8
+ calculateCredits,
9
+ calculateResolutionMultiplier,
10
+ convertCostToCredits,
11
+ } from "./credit-calculations";
12
+
13
+ // Time & Duration Calculations
14
+ export {
15
+ calculateAgeMs,
16
+ calculateAgeSeconds,
17
+ calculateAgeMinutes,
18
+ isOlderThan,
19
+ calculateDurationMs,
20
+ formatDuration,
21
+ calculatePollingInterval,
22
+ calculateEstimatedPollingTime,
23
+ } from "./time-calculations";
24
+
25
+ // General Cost & Value Calculations
26
+ export {
27
+ calculatePercentage,
28
+ calculateProgress,
29
+ calculateRemaining,
30
+ calculateFilteredCount,
31
+ calculatePaginationSlice,
32
+ calculateHasMore,
33
+ calculateBase64Size,
34
+ calculateBase64SizeMB,
35
+ isBase64SizeWithinLimit,
36
+ calculateConfidenceScore,
37
+ calculateAspectRatio,
38
+ calculateHeightFromAspectRatio,
39
+ calculateWidthFromAspectRatio,
40
+ calculateImageMemoryUsage,
41
+ calculateMemoryMB,
42
+ calculateSafeBatchSize,
43
+ clamp,
44
+ lerp,
45
+ mapRange,
46
+ } from "./cost-calculations";
@@ -0,0 +1,7 @@
1
+ /**
2
+ * Date Utilities
3
+ * Date normalization and timestamp operations
4
+ */
5
+
6
+ export * from "./normalization";
7
+ export * from "./timestamp";
@@ -0,0 +1,7 @@
1
+ /**
2
+ * Shared Kernel
3
+ */
4
+
5
+ export * from "./infrastructure/validation";
6
+ export * from "./domain/base-generation-strategy";
7
+ export * from "./application/hooks/use-generation-handler";
@@ -0,0 +1,36 @@
1
+ /**
2
+ * Shared Validation Utilities
3
+ */
4
+
5
+ // Export all from common-validators
6
+ export * from "./common-validators";
7
+ export * from "./common-validators.types";
8
+
9
+ // Export functions from advanced-validator
10
+ export { combineValidationResults } from "../../../infrastructure/validation/advanced-validator";
11
+
12
+ // Export error handling utilities
13
+ export { handleError } from "./error-handler";
14
+ export { ErrorType } from "./error-handler.types";
15
+
16
+ /**
17
+ * Validate required fields in an object
18
+ */
19
+ export function validateRequiredFields<T extends Record<string, unknown>>(
20
+ obj: T,
21
+ requiredFields: (keyof T)[]
22
+ ): { isValid: boolean; missingFields: string[] } {
23
+ const missingFields: string[] = [];
24
+
25
+ for (const field of requiredFields) {
26
+ const value = obj[field];
27
+ if (value === undefined || value === null || value === '') {
28
+ missingFields.push(String(field));
29
+ }
30
+ }
31
+
32
+ return {
33
+ isValid: missingFields.length === 0,
34
+ missingFields,
35
+ };
36
+ }