@umituz/react-native-ai-generation-content 1.26.31 → 1.26.32
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.26.
|
|
3
|
+
"version": "1.26.32",
|
|
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",
|
package/src/index.ts
CHANGED
|
@@ -56,7 +56,7 @@ export {
|
|
|
56
56
|
isValidBase64, getBase64Size, getBase64SizeMB, prepareImage, createDevCallbacks, createFeatureUtils,
|
|
57
57
|
showVideoGenerationSuccess, handleGenerationError, showContentModerationWarning,
|
|
58
58
|
saveMediaToGallery, shareMedia, createSaveHandler, createShareHandler, createMediaHandlers,
|
|
59
|
-
mapJobStatusToGenerationStatus,
|
|
59
|
+
mapJobStatusToGenerationStatus,
|
|
60
60
|
} from "./infrastructure/utils";
|
|
61
61
|
|
|
62
62
|
export { distinctBy } from "./utils/arrayUtils";
|
|
@@ -1,55 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* Language Utilities
|
|
3
|
-
* Enhances prompts with language instructions for multi-language support
|
|
4
|
-
*/
|
|
5
|
-
|
|
6
|
-
const LANGUAGE_NAMES: Record<string, string> = {
|
|
7
|
-
tr: "Turkish",
|
|
8
|
-
es: "Spanish",
|
|
9
|
-
fr: "French",
|
|
10
|
-
de: "German",
|
|
11
|
-
it: "Italian",
|
|
12
|
-
pt: "Portuguese",
|
|
13
|
-
ru: "Russian",
|
|
14
|
-
ja: "Japanese",
|
|
15
|
-
ko: "Korean",
|
|
16
|
-
zh: "Chinese",
|
|
17
|
-
ar: "Arabic",
|
|
18
|
-
hi: "Hindi",
|
|
19
|
-
th: "Thai",
|
|
20
|
-
vi: "Vietnamese",
|
|
21
|
-
pl: "Polish",
|
|
22
|
-
nl: "Dutch",
|
|
23
|
-
sv: "Swedish",
|
|
24
|
-
no: "Norwegian",
|
|
25
|
-
da: "Danish",
|
|
26
|
-
fi: "Finnish",
|
|
27
|
-
ro: "Romanian",
|
|
28
|
-
bg: "Bulgarian",
|
|
29
|
-
uk: "Ukrainian",
|
|
30
|
-
cs: "Czech",
|
|
31
|
-
hu: "Hungarian",
|
|
32
|
-
id: "Indonesian",
|
|
33
|
-
ms: "Malay",
|
|
34
|
-
tl: "Filipino",
|
|
35
|
-
};
|
|
36
|
-
|
|
37
|
-
export function enhancePromptWithLanguage(
|
|
38
|
-
prompt: string,
|
|
39
|
-
languageCode?: string,
|
|
40
|
-
): string {
|
|
41
|
-
if (!languageCode || languageCode === "en") {
|
|
42
|
-
return prompt;
|
|
43
|
-
}
|
|
44
|
-
|
|
45
|
-
const languageName = LANGUAGE_NAMES[languageCode] || "the user's language";
|
|
46
|
-
return `${prompt}\n\nPlease respond in ${languageName} language.`;
|
|
47
|
-
}
|
|
48
|
-
|
|
49
|
-
export function getSupportedLanguages(): string[] {
|
|
50
|
-
return Object.keys(LANGUAGE_NAMES);
|
|
51
|
-
}
|
|
52
|
-
|
|
53
|
-
export function getLanguageName(code: string): string | undefined {
|
|
54
|
-
return LANGUAGE_NAMES[code];
|
|
55
|
-
}
|