@akropolys/kiku 1.6.0 → 1.6.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.
package/dist/index.mjs CHANGED
@@ -1323,8 +1323,8 @@ function SourcesCarousel({ sources, defaultCurrency, onSelectSource, referencedI
1323
1323
  const scrollNext = () => {
1324
1324
  railRef.current?.scrollBy({ left: 170, behavior: "smooth" });
1325
1325
  };
1326
- const referenced = sources.filter((s) => s.id && referencedIds.includes(s.id));
1327
- const display = referencedIds.length > 0 ? referenced : sources;
1326
+ const display = sources.filter((s) => s.id && referencedIds.includes(s.id));
1327
+ if (display.length === 0) return null;
1328
1328
  return /* @__PURE__ */ jsxs6("div", { className: "hsk-cb-sources-wrap", children: [
1329
1329
  /* @__PURE__ */ jsx7("div", { className: "hsk-cb-sources", ref: railRef, children: display.map((src, si) => {
1330
1330
  const isReferenced = !!(src.id && referencedIds.includes(src.id));
@@ -1956,7 +1956,7 @@ function ChatModal({
1956
1956
  ] });
1957
1957
  })(),
1958
1958
  isLast && lastIntent === "compare" && sources.length >= 2 && !replayMessages && /* @__PURE__ */ jsx7(ComparisonMatrix, { sources, defaultCurrency }),
1959
- isLast && sources.length > 0 && lastIntent !== "compare" && lastAction?.type !== "request_phone" && lastAction?.type !== "awaiting_payment" && lastAction?.type !== "checkout" && !msg.cartSnapshot && /* @__PURE__ */ jsx7(
1959
+ isLast && referencedIds.length > 0 && lastIntent !== "compare" && lastAction?.type !== "request_phone" && lastAction?.type !== "awaiting_payment" && lastAction?.type !== "checkout" && !msg.cartSnapshot && /* @__PURE__ */ jsx7(
1960
1960
  SourcesCarousel,
1961
1961
  {
1962
1962
  sources,
@@ -1985,7 +1985,7 @@ function ChatModal({
1985
1985
  SmartContextPills,
1986
1986
  {
1987
1987
  intent: lastIntent,
1988
- sources,
1988
+ sources: sources.filter((s) => s.id && referencedIds.includes(s.id)),
1989
1989
  onSend: handleSend,
1990
1990
  loading
1991
1991
  }