Recently, after replacing the original text with the translated versions, I noticed that some text overflows its text container and becomes invisible.
The issue is that your code relies on spaces to determine where to wrap lines. For languages that don’t use spaces between words, such as Chinese and Japanese, the only workaround is to manually insert \n wherever a line break is needed.
If you plan to support I18n in the future, this is something you’ll need to address first. The text-wrapping logic should support languages that don’t use spaces as word separators.
