This sample demonstrates the template functionality of the Chat UI control, showing how you can customize various elements of the chat interface. It highlights the ability to adjust the appearance of message items, time breaks, and empty chat screens using templates.
In this example, a bot provides order tracking updates by customizing each message using the templates. The messageTemplate property controls the layout of messages, including the avatar, message content, and suggestions. The timeBreakTemplate adjusts the display of time breaks, showing either "Today" or the specific date. The bot sends a default response when a message is sent, and suggestions appear below the message. When a suggestion is clicked, the bot replies with a new message or set of suggestions, demonstrating how templates enhance the interaction flow within the Chat UI control.