Skip to contentSkip to navigationSkip to topbar
Page toolsOn this page
Looking for more inspiration?Visit the

Use custom styling for Webchat components in Webchat 3.x.x


To customize the style of Flex Webchat components, enable the isCustomizationEnabled attribute when you initialize Webchat. After you enable this attribute, override the CSS classes of the components that you want to customize.


Configure customization

configure-customization page anchor
1
const appConfig = {
2
// Webchat configuration
3
deploymentKey: "{your_key}", // Replace with your deployment key
4
appStatus: "open",
5
isCustomizationEnabled: true
6
}

Components and override classes

components-and-override-classes page anchor

Use the following class names to override the styling for each component:

ComponentComponent class nameComponent description
entryPointtwilio-webchat-entry-pointButton that launches the webchat widget
headerPaneltwilio-webchat-header-panelHeader panel of the webchat widget
headerPanelTitletwilio-webchat-header-panel-titleTitle in the header panel of the webchat widget
headerPanelCloseIcontwilio-webchat-header-panel-close-iconClose icon in the header panel of the webchat widget
webchatPaneltwilio-webchat-panelMain container of the webchat widget
startChatBtntwilio-webchat-start-chat-btnButton that starts the chat after the pre-engagement form
chatBubbleCustomertwilio-webchat-chat-bubble-customerChat bubble for customer messages
chatBubbleAgenttwilio-webchat-chat-bubble-agentChat bubble for agent messages
chatBubbleAgentAvatartwilio-webchat-chat-bubble-agent-avatarAvatar in the agent chat bubble
endChatModaltwilio-webchat-end-chat-modalModal that appears when the user clicks End chat
endChatModalCancelBtntwilio-webchat-end-chat-modal-cancel-btnCancel button in the end-chat modal
endChatModalConfirmBtntwilio-webchat-end-chat-modal-confirm-btnConfirm button in the end-chat modal
loadingSpinnertwilio-webchat-loading-spinnerSpinner that appears while the webchat widget loads
messageInputtwilio-webchat-message-inputMessage input field
messageInputSendBtntwilio-webchat-message-input-send-btnSend button for the message input field
newChatBtntwilio-webchat-new-chat-btnButton that starts a new chat after ending a chat
preEngagementFormtwilio-webchat-pre-engagement-formPre-engagement form container
preEngagementFormTitletwilio-webchat-pre-engagement-form-titleTitle of the pre-engagement form
preEngagementFormDescriptiontwilio-webchat-pre-engagement-form-descriptionDescription of the pre-engagement form
notificationBartwilio-webchat-notification-barNotification bar that appears above the message input field