feat: rename offline to web

This commit is contained in:
Mohamed Marrouchi
2024-10-22 14:03:15 +01:00
parent 1fc58f4496
commit a3d7b83511
41 changed files with 375 additions and 410 deletions

View File

@@ -61,7 +61,7 @@ Once the widget is built, you can easily embed it into any webpage. Here's an ex
ReactDOM.render(
el(HexabotWidget, {
apiUrl: 'https://api.yourdomain.com',
channel: 'offline-channel',
channel: 'web-channel',
token: 'token123',
}),
domContainer,
@@ -96,7 +96,7 @@ To prevent the website css from conflicting with the chat widget css, we can lev
ReactDOM.render(
React.createElement(HexabotWidget, {
apiUrl: 'https://api.yourdomain.com',
channel: 'offline-channel',
channel: 'web-channel',
token: 'token123',
}),
shadowContainer,

View File

@@ -34,7 +34,7 @@
ReactDOM.render(
React.createElement(HexabotWidget, {
apiUrl: 'http://localhost:4000',
channel: 'offline-channel',
channel: 'web-channel',
token: 'token123',
}),
shadowContainer,

View File

@@ -18,7 +18,7 @@ ReactDOM.createRoot(document.getElementById('root')!).render(
<ChatWidget
{...{
apiUrl: process.env.REACT_APP_WIDGET_API_URL || 'http://localhost:4000',
channel: process.env.REACT_APP_WIDGET_CHANNEL || 'offline-channel',
channel: process.env.REACT_APP_WIDGET_CHANNEL || 'web-channel',
token: process.env.REACT_APP_WIDGET_TOKEN || 'token123',
language: 'en',
}}

View File

@@ -82,7 +82,7 @@ export type TChannelData = {
};
export type TRequestSession = {
offline?: {
web?: {
profile: ISubscriber;
isSocket: boolean;
// @TODO : not sure why we added messageQuery (long pooling ?)