I don't know of that's actually needed and correct, some coder with Persian reading skills would need to check, but chatgpt gave me this answer:
"In this updated example, the "android:textDirection" attribute is used to specify that each string should be rendered using the RTL directionality. This ensures that the mixed-language strings are displayed correctly, with the Persian text flowing from right to left and the English text flowing from left to right."


