How to change locale to respect direction?

Jake Jones 6 Reputation points
2020-06-30T18:19:56.397+00:00

I can't figure out how to make the bot to change locale to respect direction, or even change direction without locale either will work, but how?

I am talking about webchat!

Azure AI Bot Service
Azure AI Bot Service
An Azure service that provides an integrated environment for bot development.
806 questions
0 comments No comments
{count} vote

1 answer

Sort by: Most helpful
  1. Ali Heikal 201 Reputation points
    2020-06-30T20:04:07.177+00:00

    If you are referring to the directional flow of a language, it support Right-to-Left (RTL), Left-to-Right (LTR), and Bidirectional (BiDi)

    For Right-to-Left (RTL):

    • You can add and set the Web Chat dir property to rtl
    • You can add and set the Web Chat locale prop to an RTL language, e.g. ar-EG and it will automatically set the direction to rtl

    For Left-to-Right (LTR):

    • You can add and set the Web Chat dir property to ltr
    • You can add and set the Web Chat locale prop to an LTR language, e.g. en-US and it will automatically set the direction to ltr

    The available properties for dir are: ltr, rtl, and auto

    You can check this sample which shows more in depth on how to change locale and direction for RTL languages on Web Chat

    3 people found this answer helpful.