dhre-ui-kit 0.0.384 → 0.0.385
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/lib/index.js +2 -2
- package/lib/index.js.map +1 -1
- package/lib/index.mjs +2 -2
- package/lib/index.mjs.map +1 -1
- package/package.json +1 -1
package/lib/index.mjs
CHANGED
|
@@ -353,10 +353,10 @@ const CustomTypography = ({
|
|
|
353
353
|
const translateText = async () => {
|
|
354
354
|
try {
|
|
355
355
|
const res = await translate(text ?? "", { to: "ar" });
|
|
356
|
-
setTranslatedText(res?.text);
|
|
356
|
+
setTranslatedText(translateToArabic ? res?.text : text);
|
|
357
357
|
} catch (error) {
|
|
358
358
|
console.error("Translation error:", error);
|
|
359
|
-
setTranslatedText(
|
|
359
|
+
setTranslatedText(text);
|
|
360
360
|
}
|
|
361
361
|
};
|
|
362
362
|
translateText();
|