@kite-copilot/chat-panel 0.2.44 → 0.2.46

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/dist/index.cjs CHANGED
@@ -1077,7 +1077,7 @@ function TypingIndicator({ className = "" }) {
1077
1077
 
1078
1078
  // src/ChatPanel.tsx
1079
1079
  var import_jsx_runtime10 = require("react/jsx-runtime");
1080
- var CHAT_PANEL_VERSION = true ? "0.2.44" : "dev";
1080
+ var CHAT_PANEL_VERSION = true ? "0.2.46" : "dev";
1081
1081
  var DEFAULT_AGENT_URL = "http://localhost:5002";
1082
1082
  var PANEL_WIDTH = 340;
1083
1083
  function unescapeJsonString(str) {
@@ -1552,6 +1552,37 @@ function ChatPanel({
1552
1552
  enabled: !!effectiveProductBackendUrl && orgConfigState.status === "success"
1553
1553
  // Only enable after config is fetched
1554
1554
  });
1555
+ React6.useEffect(() => {
1556
+ if (!effectiveProductBackendUrl || orgConfigState.status !== "success") {
1557
+ return;
1558
+ }
1559
+ const testProductBackendEndpoint = async () => {
1560
+ const url = `${effectiveProductBackendUrl}/getDocument/snowkite/categories/`;
1561
+ console.log("[KiteChat TEST] Testing product backend connectivity...");
1562
+ console.log("[KiteChat TEST] URL:", url);
1563
+ try {
1564
+ const response = await fetch(url, {
1565
+ method: "GET",
1566
+ // Note: not using credentials: 'include' to avoid CORS issues with wildcard
1567
+ headers: {
1568
+ "Accept": "application/json"
1569
+ }
1570
+ });
1571
+ console.log("[KiteChat TEST] Response status:", response.status);
1572
+ console.log("[KiteChat TEST] Response ok:", response.ok);
1573
+ if (response.ok) {
1574
+ const data = await response.json();
1575
+ console.log("[KiteChat TEST] SUCCESS - product backend reachable, data:", data);
1576
+ } else {
1577
+ const errorText = await response.text();
1578
+ console.log("[KiteChat TEST] FAILED - status:", response.status, "body:", errorText);
1579
+ }
1580
+ } catch (error) {
1581
+ console.error("[KiteChat TEST] ERROR:", error);
1582
+ }
1583
+ };
1584
+ testProductBackendEndpoint();
1585
+ }, [effectiveProductBackendUrl, orgConfigState.status]);
1555
1586
  const effectiveUser = React6.useMemo(() => {
1556
1587
  if (authState.status === "authenticated") {
1557
1588
  return {
package/dist/index.js CHANGED
@@ -31,7 +31,7 @@ import {
31
31
  cn,
32
32
  createKiteChat,
33
33
  useGuideCursor
34
- } from "./chunk-G74XTXWW.js";
34
+ } from "./chunk-4HIWUL6E.js";
35
35
  export {
36
36
  ApiKeyList,
37
37
  AssistantActivity,
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@kite-copilot/chat-panel",
3
- "version": "0.2.44",
3
+ "version": "0.2.46",
4
4
  "description": "AI-powered chat panel SDK with programmatic lifecycle control",
5
5
  "type": "module",
6
6
  "main": "./dist/index.cjs",