keystone-design-bootstrap 1.0.40 → 1.0.41

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 CHANGED
@@ -6657,7 +6657,7 @@ var TeamGrid = ({
6657
6657
  alt: member.name || "Team member",
6658
6658
  className: "h-78 w-full object-cover md:h-74 rounded-2xl"
6659
6659
  }
6660
- ), /* @__PURE__ */ React23.createElement("div", null, /* @__PURE__ */ React23.createElement("h3", { className: "text-lg font-semibold text-primary md:text-xl" }, member.name), /* @__PURE__ */ React23.createElement("p", { className: "text-md text-brand-secondary md:mt-0.5 md:text-lg" }, member.position), bio && /* @__PURE__ */ React23.createElement("p", { className: "mt-4 text-md text-tertiary line-clamp-3" }, bio)));
6660
+ ), /* @__PURE__ */ React23.createElement("div", null, /* @__PURE__ */ React23.createElement("h3", { className: "text-lg font-semibold text-primary md:text-xl" }, member.name), /* @__PURE__ */ React23.createElement("p", { className: "text-md text-brand-secondary md:mt-0.5 md:text-lg" }, member.position), bio && /* @__PURE__ */ React23.createElement("p", { className: "mt-4 text-md text-tertiary leading-relaxed" }, bio)));
6661
6661
  }))) : /* @__PURE__ */ React23.createElement("div", { className: "text-center mt-12" }, /* @__PURE__ */ React23.createElement("p", { className: "text-gray-500" }, "No team members available"))));
6662
6662
  };
6663
6663
 
@@ -8629,7 +8629,7 @@ var ServicesHome2 = ({
8629
8629
  services: servicesData,
8630
8630
  title = ""
8631
8631
  }) => {
8632
- const services = Array.isArray(servicesData) ? servicesData.slice(0, 6) : [];
8632
+ const services = Array.isArray(servicesData) ? servicesData : [];
8633
8633
  return /* @__PURE__ */ React.createElement("section", null, /* @__PURE__ */ React.createElement("div", { className: "mx-auto max-w-container px-4 md:px-8" }, /* @__PURE__ */ React.createElement("div", { className: "mb-12 text-center" }, /* @__PURE__ */ React.createElement("h2", { className: "font-display text-4xl font-normal text-fg-primary md:text-5xl" }, title)), services.length > 0 ? /* @__PURE__ */ React.createElement("div", { className: "grid grid-cols-1 gap-12 md:grid-cols-2 lg:grid-cols-3" }, services.map((service) => {
8634
8634
  const description = service.summary || (service.description_markdown ? service.description_markdown.replace(/[#*\[\]()]/g, "").trim().substring(0, 150) : "");
8635
8635
  return /* @__PURE__ */ React.createElement("div", { key: service.id, className: "flex flex-col" }, /* @__PURE__ */ React.createElement("div", { className: "w-full h-64 mb-6 overflow-hidden" }, /* @__PURE__ */ React.createElement(
@@ -18704,7 +18704,7 @@ var TeamGrid3 = ({
18704
18704
  alt: member.name || "Team member",
18705
18705
  className: "h-78 w-full object-cover md:h-74 rounded-2xl"
18706
18706
  }
18707
- ), /* @__PURE__ */ React57.createElement("div", null, /* @__PURE__ */ React57.createElement("h3", { className: "text-lg font-semibold text-primary md:text-xl" }, member.name), /* @__PURE__ */ React57.createElement("p", { className: "text-md text-brand-secondary md:mt-0.5 md:text-lg" }, member.position), bio && /* @__PURE__ */ React57.createElement("p", { className: "mt-4 text-md text-tertiary line-clamp-3" }, bio)));
18707
+ ), /* @__PURE__ */ React57.createElement("div", null, /* @__PURE__ */ React57.createElement("h3", { className: "text-lg font-semibold text-primary md:text-xl" }, member.name), /* @__PURE__ */ React57.createElement("p", { className: "text-md text-brand-secondary md:mt-0.5 md:text-lg" }, member.position), bio && /* @__PURE__ */ React57.createElement("p", { className: "mt-4 text-md text-tertiary leading-relaxed" }, bio)));
18708
18708
  }))) : /* @__PURE__ */ React57.createElement("div", { className: "text-center mt-12" }, /* @__PURE__ */ React57.createElement("p", { className: "text-gray-500" }, "No team members available"))));
18709
18709
  };
18710
18710
  registerThemeVariant("team-grid", "balance", TeamGrid3);
@@ -19072,28 +19072,21 @@ function ChatWidget({
19072
19072
  }, [messages]);
19073
19073
  const pollForAgentReply = () => {
19074
19074
  setWaitingForReply(true);
19075
- const initialCount = messages.length;
19076
19075
  let attempts = 0;
19077
19076
  const maxAttempts = 30;
19078
- console.log(`[ChatWidget] Starting poll for agent reply (initial count: ${initialCount})`);
19079
19077
  const pollInterval = setInterval(async () => {
19080
- var _a;
19081
19078
  attempts++;
19082
19079
  try {
19083
19080
  const newMessages = await loadMessages();
19084
- console.log(`[ChatWidget] Poll attempt ${attempts}: got ${newMessages.length} messages (initial: ${initialCount})`);
19085
- if (newMessages.length > initialCount) {
19086
- const latestMessage = newMessages[newMessages.length - 1];
19087
- console.log(`[ChatWidget] New message detected: sender_type=${latestMessage.sender_type}, body=${(_a = latestMessage.body) == null ? void 0 : _a.substring(0, 50)}`);
19088
- if (latestMessage.sender_type === "agent") {
19089
- console.log("[ChatWidget] \u2713 Received agent reply!");
19090
- clearInterval(pollInterval);
19091
- setWaitingForReply(false);
19092
- setIsLoading(false);
19093
- }
19081
+ const latest = newMessages[newMessages.length - 1];
19082
+ const hasAgentReplyWithBody = (latest == null ? void 0 : latest.sender_type) === "agent" && (latest == null ? void 0 : latest.body) != null && String(latest.body).trim() !== "";
19083
+ if (hasAgentReplyWithBody) {
19084
+ clearInterval(pollInterval);
19085
+ setWaitingForReply(false);
19086
+ setIsLoading(false);
19087
+ return;
19094
19088
  }
19095
19089
  if (attempts >= maxAttempts) {
19096
- console.warn("[ChatWidget] \u26A0 Polling timeout - no reply received after 30s");
19097
19090
  clearInterval(pollInterval);
19098
19091
  setWaitingForReply(false);
19099
19092
  setIsLoading(false);