embeddedaichatux 2.0.0 → 2.0.1

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.
Files changed (2) hide show
  1. package/EmbeddedChat.js +2 -7
  2. package/package.json +1 -1
package/EmbeddedChat.js CHANGED
@@ -19,12 +19,7 @@
19
19
  this.hasRefreshed = false; // Flag to prevent endless loop
20
20
  this.conversationId = null;
21
21
  this.userTokenProvider = options.userTokenProvider;
22
-
23
- try {
24
- this.targetOrigin = new URL(this.serverUrl).origin;
25
- } catch {
26
- this.targetOrigin = "*";
27
- }
22
+ this.targetOrigin = "*";
28
23
 
29
24
  // Determine transition styles
30
25
  const transitionStyle = this.enableAnimation ? 'transition: height 0.3s ease, opacity 0.3s ease;' : '';
@@ -46,7 +41,7 @@
46
41
  }
47
42
 
48
43
  isSafari() {
49
- var ua = navigator.userAgent.toLowerCase();
44
+ const ua = navigator.userAgent.toLowerCase();
50
45
  return ua.indexOf('safari') != -1 && ua.indexOf('chrome') == -1;
51
46
  }
52
47
 
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "embeddedaichatux",
3
- "version": "2.0.0",
3
+ "version": "2.0.1",
4
4
  "description": "A lightweight and customizable embedded AI chat UI component that seamlessly integrates into web applications, offering minimized and expanded views, with iframe-based content rendering.",
5
5
  "main": "EmbeddedChat.js",
6
6
  "scripts": {