Skip to main content

Webchat Settings

The Webchat settings component can be appended at the end of a message to change Webchat properties dynamically.

Properties

PropertyTypeDescriptionRequiredDefault value
themeObjectRefer theme optionsNo-
blockInputsObjectRefer to block inputsNo-
persistentMenuObjectRefer to persistent menuNo-
enableEmojiPickerbooleanEnable the selection of an emojiNo-
enableAttachmentsbooleanEnable the selection of an attachmentNo-
enableUserInputbooleanEnable user inputNo-
enableAnimationsbooleanEnable animated elementsNo-

Example

import React from 'react'
import { Text, WebchatSettings } from '@botonic/react'

export default class extends React.Component {
render() {
return (
<>
<Text>Ok dude 😉</Text>
<WebchatSettings
theme={{
brand: { color: 'orange' },
}}
enableEmojiPicker={true}
persistentMenu={[
{ label: 'option1', payload: 'opt1' },
{ label: 'option2', payload: 'opt2' },
]}
enableUserInput={true}
/>
</>
)
}
}

Note: you can get a more detailed example in the Webchat section.