mirror of
https://github.com/farcasclaudiu/Flowise.git
synced 2026-06-25 23:01:12 +03:00
Embed Chat configuration updated (#2648)
This commit is contained in:
@@ -104,6 +104,24 @@ const buttonConfig = (isReact = false) => {
|
||||
}`
|
||||
}
|
||||
|
||||
const tooltipConfig = (isReact = false) => {
|
||||
return isReact
|
||||
? `tooltip: {
|
||||
showTooltip: true,
|
||||
tooltipMessage: 'Hi There 👋!',
|
||||
tooltipBackgroundColor: 'black',
|
||||
tooltipTextColor: 'white',
|
||||
tooltipFontSize: 16,
|
||||
}`
|
||||
: `tooltip: {
|
||||
showTooltip: true,
|
||||
tooltipMessage: 'Hi There 👋!',
|
||||
tooltipBackgroundColor: 'black',
|
||||
tooltipTextColor: 'white',
|
||||
tooltipFontSize: 16,
|
||||
}`
|
||||
}
|
||||
|
||||
const chatwindowConfig = (isReact = false) => {
|
||||
return isReact
|
||||
? `chatWindow: {
|
||||
@@ -136,6 +154,7 @@ const chatwindowConfig = (isReact = false) => {
|
||||
sendButtonColor: '#3B81F6',
|
||||
maxChars: 50,
|
||||
maxCharsWarningMessage: 'You exceeded the characters limit. Please input less than 50 characters.',
|
||||
autoFocus: true, // If not used, autofocus is disabled on mobile and enabled on desktop. true enables it on both, false disables it on both.
|
||||
},
|
||||
feedback: {
|
||||
color: '#303235',
|
||||
@@ -177,6 +196,7 @@ const chatwindowConfig = (isReact = false) => {
|
||||
sendButtonColor: '#3B81F6',
|
||||
maxChars: 50,
|
||||
maxCharsWarningMessage: 'You exceeded the characters limit. Please input less than 50 characters.',
|
||||
autoFocus: true, // If not used, autofocus is disabled on mobile and enabled on desktop. true enables it on both, false disables it on both.
|
||||
},
|
||||
feedback: {
|
||||
color: '#303235',
|
||||
@@ -201,6 +221,7 @@ const embedPopupHtmlCodeCustomization = (chatflowid) => {
|
||||
},
|
||||
theme: {
|
||||
${buttonConfig()},
|
||||
${tooltipConfig()},
|
||||
${chatwindowConfig()}
|
||||
}
|
||||
})
|
||||
@@ -217,6 +238,7 @@ const App = () => {
|
||||
apiHost="${baseURL}"
|
||||
theme={{
|
||||
${buttonConfig(true)},
|
||||
${tooltipConfig(true)},
|
||||
${chatwindowConfig(true)}
|
||||
}}
|
||||
/>
|
||||
|
||||
Reference in New Issue
Block a user