@walkspan/chatbot 0.2.6 → 0.2.8
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.js +2 -2
- package/dist/index.mjs +2 -2
- package/package.json +1 -1
package/dist/index.js
CHANGED
|
@@ -112,11 +112,11 @@ var FloatingChatbot = ({
|
|
|
112
112
|
className: `fixed z-50 ${positionClasses[position]} w-96 max-w-[90vw] h-[500px] bg-white rounded-xl shadow-xl flex flex-col`
|
|
113
113
|
},
|
|
114
114
|
/* @__PURE__ */ import_react.default.createElement("div", { className: "flex items-center justify-between p-4 border-b bg-[#f1592a] text-white rounded-t-xl" }, /* @__PURE__ */ import_react.default.createElement("div", { className: "font-medium" }, title), /* @__PURE__ */ import_react.default.createElement("button", { onClick: () => setOpen(false) }, /* @__PURE__ */ import_react.default.createElement(import_fa.FaTimes, null))),
|
|
115
|
-
/* @__PURE__ */ import_react.default.createElement("div", { className: "flex-1 p-4 overflow-y-auto space-y-2" }, messages.map((m) => /* @__PURE__ */ import_react.default.createElement(
|
|
115
|
+
/* @__PURE__ */ import_react.default.createElement("div", { className: "flex-1 p-4 overflow-y-auto space-y-2" }, messages.length === 0 && !isLoading && /* @__PURE__ */ import_react.default.createElement("div", { className: "flex flex-col items-center justify-center h-full text-center px-4" }, /* @__PURE__ */ import_react.default.createElement("h2", { className: "text-xl font-medium text-black mb-2" }, "Welcome to ", /* @__PURE__ */ import_react.default.createElement("span", { className: "text-[#f1592a]" }, "Walkspan"), " AI"), /* @__PURE__ */ import_react.default.createElement("p", { className: "text-sm text-[#71717a] leading-relaxed" }, "I'm your neighborhood intelligence assistant. I help you compare neighborhoods and find the right place for your lifestyle. How can I help?")), messages.map((m) => /* @__PURE__ */ import_react.default.createElement(
|
|
116
116
|
"div",
|
|
117
117
|
{
|
|
118
118
|
key: m.id,
|
|
119
|
-
className: `max-w-[80%] py-2 px-5 rounded-3xl text-sm break-all${m.type === "user" ? "ml-auto bg-[#edf0f6] text-black" : "bg-[#f1592a] text-white"}`
|
|
119
|
+
className: `max-w-[80%] py-2 px-5 rounded-3xl text-sm break-all ${m.type === "user" ? "ml-auto bg-[#edf0f6] text-black" : "bg-[#f1592a] text-white"}`
|
|
120
120
|
},
|
|
121
121
|
m == null ? void 0 : m.message,
|
|
122
122
|
m.type !== "user" && m.link && /* @__PURE__ */ import_react.default.createElement(
|
package/dist/index.mjs
CHANGED
|
@@ -76,11 +76,11 @@ var FloatingChatbot = ({
|
|
|
76
76
|
className: `fixed z-50 ${positionClasses[position]} w-96 max-w-[90vw] h-[500px] bg-white rounded-xl shadow-xl flex flex-col`
|
|
77
77
|
},
|
|
78
78
|
/* @__PURE__ */ React.createElement("div", { className: "flex items-center justify-between p-4 border-b bg-[#f1592a] text-white rounded-t-xl" }, /* @__PURE__ */ React.createElement("div", { className: "font-medium" }, title), /* @__PURE__ */ React.createElement("button", { onClick: () => setOpen(false) }, /* @__PURE__ */ React.createElement(FaTimes, null))),
|
|
79
|
-
/* @__PURE__ */ React.createElement("div", { className: "flex-1 p-4 overflow-y-auto space-y-2" }, messages.map((m) => /* @__PURE__ */ React.createElement(
|
|
79
|
+
/* @__PURE__ */ React.createElement("div", { className: "flex-1 p-4 overflow-y-auto space-y-2" }, messages.length === 0 && !isLoading && /* @__PURE__ */ React.createElement("div", { className: "flex flex-col items-center justify-center h-full text-center px-4" }, /* @__PURE__ */ React.createElement("h2", { className: "text-xl font-medium text-black mb-2" }, "Welcome to ", /* @__PURE__ */ React.createElement("span", { className: "text-[#f1592a]" }, "Walkspan"), " AI"), /* @__PURE__ */ React.createElement("p", { className: "text-sm text-[#71717a] leading-relaxed" }, "I'm your neighborhood intelligence assistant. I help you compare neighborhoods and find the right place for your lifestyle. How can I help?")), messages.map((m) => /* @__PURE__ */ React.createElement(
|
|
80
80
|
"div",
|
|
81
81
|
{
|
|
82
82
|
key: m.id,
|
|
83
|
-
className: `max-w-[80%] py-2 px-5 rounded-3xl text-sm break-all${m.type === "user" ? "ml-auto bg-[#edf0f6] text-black" : "bg-[#f1592a] text-white"}`
|
|
83
|
+
className: `max-w-[80%] py-2 px-5 rounded-3xl text-sm break-all ${m.type === "user" ? "ml-auto bg-[#edf0f6] text-black" : "bg-[#f1592a] text-white"}`
|
|
84
84
|
},
|
|
85
85
|
m == null ? void 0 : m.message,
|
|
86
86
|
m.type !== "user" && m.link && /* @__PURE__ */ React.createElement(
|