cevro-messenger-sdk 0.1.13 → 0.1.14

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/README.md CHANGED
@@ -41,6 +41,8 @@ All options are passed inside `window.cevroSettings` in the snippet above:
41
41
  | `primaryColor` | `string` | No | Primary brand color (hex) |
42
42
  | `theme` | `object` | No | Custom theme colors (see below) |
43
43
  | `locale` | `object` | No | UI text overrides (see below) |
44
+ | `hideDefaultLauncher` | `boolean` | No | Hide the default launcher button |
45
+ | `customLauncherSelector` | `string` | No | CSS selector for your own launcher element |
44
46
  | `zIndex` | `number` | No | Z-index for the widget |
45
47
 
46
48
  ### Player
@@ -192,8 +194,30 @@ Cevro('update', {
192
194
  email: 'user@example.com',
193
195
  },
194
196
  });
197
+
198
+ Cevro('showLauncher'); // Show the launcher button
199
+ Cevro('hideLauncher'); // Hide the launcher button
200
+ ```
201
+
202
+ ### Custom Launcher
203
+
204
+ Hide the default launcher and use your own button:
205
+
206
+ ```html
207
+ <button id="my-chat-btn">Chat with us</button>
208
+
209
+ <script>
210
+ window.cevroSettings = {
211
+ workspaceId: 'YOUR_WORKSPACE_ID',
212
+ brandId: 'YOUR_BRAND_ID',
213
+ hideDefaultLauncher: true,
214
+ customLauncherSelector: '#my-chat-btn',
215
+ };
216
+ </script>
195
217
  ```
196
218
 
219
+ Clicks on `#my-chat-btn` will toggle the chat window. You can also control the launcher programmatically with `Cevro('showLauncher')` and `Cevro('hideLauncher')`.
220
+
197
221
  ## License
198
222
 
199
223
  MIT