@indxsearch/systm 2.25.0-beta.0 → 2.25.0-beta.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.d.ts CHANGED
@@ -55,7 +55,7 @@ export { StepProgress, type StepProgressProps, type StepProgressPart } from './c
55
55
  export { Icicle, type IcicleProps, type IcicleNode } from './components/Icicle';
56
56
  export { spinnerNames, type SpinnerName } from './components/Spinner/spinners.generated';
57
57
  export { NavigationMenu, NavigationMenuList, NavigationMenuItem, NavigationMenuTrigger, NavigationMenuContent, NavigationMenuLink, type NavigationMenuProps, type NavigationMenuTriggerProps, type NavigationMenuLinkProps } from './components/NavigationMenu/NavigationMenu';
58
- export { ChatPanel, Kbd, defaultChatHints, UserMessage, AssistantMessage, Composer, CitationRef, CitationList, StreamStatus, Suggestions, AnswerActions, ToolStep, ToolSteps, Reasoning, type ChatPanelProps, type UserMessageProps, type AssistantMessageProps, type ComposerProps, type ComposerHandle, type CitationRefProps, type CitationItem, type CitationListProps, type StreamStatusProps, type SuggestionsProps, type AnswerActionsProps, type ToolStepProps, type ToolStepsProps, type ReasoningProps, } from './components/Chat';
58
+ export { ChatPanel, Kbd, defaultChatHints, UserMessage, AssistantMessage, Composer, CitationRef, CitationList, StreamStatus, Suggestions, AnswerActions, ToolStep, ToolSteps, Reasoning, type ChatPanelProps, type UserMessageProps, type AssistantMessageProps, type ComposerProps, type ComposerHandle, type CitationRefProps, type CitationItem, type CitationListProps, type StreamStatusProps, type SuggestionsProps, type AnswerActionsProps, type ToolStepProps, type ToolStepsProps, type ReasoningProps, ChatLauncher, type ChatLauncherProps, } from './components/Chat';
59
59
  export { Truncate, type TruncateProps } from './components/Truncate/Truncate';
60
60
  export { Disclosure, type DisclosureProps } from './components/Disclosure/Disclosure';
61
61
  export { CodeCopy, type CodeCopyProps } from './components/CodeCopy/CodeCopy';
package/dist/index.es.js CHANGED
@@ -519,79 +519,80 @@ function de({ title: t, children: n, className: r = "", collapsible: i = !0, col
519
519
  });
520
520
  }
521
521
  var fe = {
522
- wrapper: "_wrapper_nc093_1",
523
- label: "_label_nc093_7",
524
- inputContainer: "_inputContainer_nc093_12",
525
- input: "_input_nc093_12",
526
- focus: "_focus_nc093_35",
527
- searchIcon: "_searchIcon_nc093_52",
528
- rightContent: "_rightContent_nc093_69",
529
- sizeMicro: "_sizeMicro_nc093_80",
530
- sizeDefault: "_sizeDefault_nc093_89",
531
- error: "_error_nc093_112",
532
- errorText: "_errorText_nc093_116"
522
+ wrapper: "_wrapper_zccyc_1",
523
+ label: "_label_zccyc_7",
524
+ inputContainer: "_inputContainer_zccyc_12",
525
+ input: "_input_zccyc_12",
526
+ focus: "_focus_zccyc_35",
527
+ searchIcon: "_searchIcon_zccyc_52",
528
+ rightContent: "_rightContent_zccyc_69",
529
+ sizeMicro: "_sizeMicro_zccyc_80",
530
+ sizeDefault: "_sizeDefault_zccyc_89",
531
+ error: "_error_zccyc_112",
532
+ errorText: "_errorText_zccyc_116",
533
+ filled: "_filled_zccyc_121"
533
534
  }, pe = {
534
535
  micro: 14,
535
536
  default: 21
536
537
  };
537
- function me({ label: t, error: n, className: r = "", showSearchIcon: i = !0, searchIcon: a, searchIconColor: o, inputSize: s = "default", showFocusBorder: c = !1, clearable: u = !0, children: p, id: m, type: _ = "search", onChange: v, ...y }) {
538
- let b = d(null), x = y.value !== void 0, [S, C] = f(String(y.defaultValue ?? "")), w = x ? String(y.value ?? "") : S, T = u && w.length > 0 && !y.disabled && !y.readOnly, E = (e) => {
539
- x || C(e.target.value), v?.(e);
540
- }, D = () => {
541
- let e = b.current;
538
+ function me({ label: t, error: n, className: r = "", showSearchIcon: i = !0, searchIcon: a, searchIconColor: o, inputSize: s = "default", showFocusBorder: c = !1, clearable: u = !0, filled: p = !1, children: m, id: _, type: v = "search", onChange: y, ...b }) {
539
+ let x = d(null), S = b.value !== void 0, [C, w] = f(String(b.defaultValue ?? "")), T = S ? String(b.value ?? "") : C, E = u && T.length > 0 && !b.disabled && !b.readOnly, D = (e) => {
540
+ S || w(e.target.value), y?.(e);
541
+ }, O = () => {
542
+ let e = x.current;
542
543
  e && (Object.getOwnPropertyDescriptor(HTMLInputElement.prototype, "value")?.set?.call(e, ""), e.dispatchEvent(new Event("input", { bubbles: !0 })), e.focus());
543
- }, O = d(null), [k, A] = f(0), j = e.Children.toArray(p).length > 0 || T;
544
+ }, k = d(null), [A, j] = f(0), N = e.Children.toArray(m).length > 0 || E;
544
545
  l(() => {
545
- let e = O.current;
546
+ let e = k.current;
546
547
  if (!e) {
547
- A(0);
548
+ j(0);
548
549
  return;
549
550
  }
550
- let t = () => A(e.offsetWidth);
551
+ let t = () => j(e.offsetWidth);
551
552
  t();
552
553
  let n = new ResizeObserver(t);
553
554
  return n.observe(e), () => n.disconnect();
554
- }, [j]);
555
- let N = e.useId(), P = m || N, F = `${P}-error`, I = pe[s], L = {};
556
- o && (L["--search-icon-color"] = o), k > 0 && (L.paddingRight = `${k + 10}px`);
557
- let R = a ?? /* @__PURE__ */ h(M, {}), z = s === "micro" ? fe.sizeMicro : fe.sizeDefault;
555
+ }, [N]);
556
+ let P = e.useId(), F = _ || P, I = `${F}-error`, L = pe[s], R = {};
557
+ o && (R["--search-icon-color"] = o), A > 0 && (R.paddingRight = `${A + 10}px`);
558
+ let z = a ?? /* @__PURE__ */ h(M, {}), B = s === "micro" ? fe.sizeMicro : fe.sizeDefault;
558
559
  return /* @__PURE__ */ g("div", {
559
- className: `${fe.wrapper} ${r}`,
560
+ className: `${fe.wrapper} ${p ? fe.filled : ""} ${r}`,
560
561
  children: [
561
562
  t && /* @__PURE__ */ h("label", {
562
- htmlFor: P,
563
+ htmlFor: F,
563
564
  className: fe.label,
564
565
  children: t
565
566
  }),
566
567
  /* @__PURE__ */ g("div", {
567
- className: `${fe.inputContainer} ${z}`,
568
+ className: `${fe.inputContainer} ${B}`,
568
569
  children: [
569
570
  i && /* @__PURE__ */ h("span", {
570
571
  className: fe.searchIcon,
571
572
  "aria-hidden": "true",
572
- children: e.cloneElement(R, {
573
- size: I,
573
+ children: e.cloneElement(z, {
574
+ size: L,
574
575
  color: o ?? "var(--search-icon-color)"
575
576
  })
576
577
  }),
577
578
  /* @__PURE__ */ h("input", {
578
- ref: b,
579
- id: P,
580
- type: _,
579
+ ref: x,
580
+ id: F,
581
+ type: v,
581
582
  className: `${fe.input} ${c ? fe.focus : ""} ${n ? fe.error : ""}`,
582
- style: L,
583
+ style: R,
583
584
  "aria-invalid": n ? "true" : "false",
584
- "aria-describedby": n ? F : void 0,
585
- ...y,
586
- onChange: E
585
+ "aria-describedby": n ? I : void 0,
586
+ ...b,
587
+ onChange: D
587
588
  }),
588
- j && /* @__PURE__ */ g("div", {
589
- ref: O,
589
+ N && /* @__PURE__ */ g("div", {
590
+ ref: k,
590
591
  className: fe.rightContent,
591
- children: [p, T && /* @__PURE__ */ h(W, {
592
+ children: [m, E && /* @__PURE__ */ h(W, {
592
593
  variant: "ghost",
593
594
  size: "micro",
594
- onClick: D,
595
+ onClick: O,
595
596
  "aria-label": "Clear search",
596
597
  children: "Clear"
597
598
  })]
@@ -599,7 +600,7 @@ function me({ label: t, error: n, className: r = "", showSearchIcon: i = !0, sea
599
600
  ]
600
601
  }),
601
602
  n && /* @__PURE__ */ h("span", {
602
- id: F,
603
+ id: I,
603
604
  className: fe.errorText,
604
605
  role: "alert",
605
606
  children: n
@@ -6227,19 +6228,81 @@ function Si({ children: e, streaming: t = !1, seconds: n, className: r = "" }) {
6227
6228
  });
6228
6229
  }
6229
6230
  var Ci = {
6231
+ launcherRoot: "_launcherRoot_s5ap7_4",
6232
+ fixed: "_fixed_s5ap7_6",
6233
+ contained: "_contained_s5ap7_7",
6234
+ right: "_right_s5ap7_8",
6235
+ left: "_left_s5ap7_10",
6236
+ window: "_window_s5ap7_13",
6237
+ head: "_head_s5ap7_16",
6238
+ title: "_title_s5ap7_17",
6239
+ headActions: "_headActions_s5ap7_18",
6240
+ body: "_body_s5ap7_19",
6241
+ footer: "_footer_s5ap7_20"
6242
+ };
6243
+ // src/components/Chat/ChatLauncher.tsx
6244
+ function wi({ title: e, children: t, headerActions: n, footer: r, label: i = "Ask", closeLabel: a = "Close", icon: s, open: c, onOpenChange: l, defaultOpen: u = !1, corner: d = "bottom-right", contained: p = !1, "aria-label": m, className: v = "" }) {
6245
+ let [y, b] = f(u), x = c ?? y, S = (e) => {
6246
+ c === void 0 && b(e), l?.(e);
6247
+ };
6248
+ o(() => {
6249
+ if (!x) return;
6250
+ let e = (e) => {
6251
+ e.key === "Escape" && S(!1);
6252
+ };
6253
+ return window.addEventListener("keydown", e), () => window.removeEventListener("keydown", e);
6254
+ });
6255
+ let C = `${p ? Ci.contained : Ci.fixed} ${d === "bottom-left" ? Ci.left : Ci.right}`;
6256
+ return /* @__PURE__ */ g("div", {
6257
+ className: `${Ci.launcherRoot} ${C} ${v}`,
6258
+ children: [/* @__PURE__ */ g("section", {
6259
+ className: Ci.window,
6260
+ hidden: !x,
6261
+ role: "dialog",
6262
+ "aria-label": m ?? (typeof e == "string" ? e : void 0),
6263
+ children: [
6264
+ /* @__PURE__ */ g("div", {
6265
+ className: Ci.head,
6266
+ children: [/* @__PURE__ */ h("span", {
6267
+ className: Ci.title,
6268
+ children: e
6269
+ }), n && /* @__PURE__ */ h("span", {
6270
+ className: Ci.headActions,
6271
+ children: n
6272
+ })]
6273
+ }),
6274
+ /* @__PURE__ */ h("div", {
6275
+ className: Ci.body,
6276
+ children: t
6277
+ }),
6278
+ r && /* @__PURE__ */ h("div", {
6279
+ className: Ci.footer,
6280
+ children: r
6281
+ })
6282
+ ]
6283
+ }), /* @__PURE__ */ h(W, {
6284
+ variant: "primary",
6285
+ iconLeft: s ?? /* @__PURE__ */ h(_, {}),
6286
+ "aria-expanded": x,
6287
+ onClick: () => S(!x),
6288
+ children: x ? a : i
6289
+ })]
6290
+ });
6291
+ }
6292
+ var Ti = {
6230
6293
  truncate: "_truncate_za4sm_1",
6231
6294
  start: "_start_za4sm_13"
6232
6295
  };
6233
6296
  // src/components/Truncate/Truncate.tsx
6234
- function wi({ children: e, side: t = "end", title: n, className: r = "" }) {
6297
+ function Ei({ children: e, side: t = "end", title: n, className: r = "" }) {
6235
6298
  let i = n ?? (typeof e == "string" ? e : void 0);
6236
6299
  return /* @__PURE__ */ h("span", {
6237
- className: `${Ci.truncate} ${t === "start" ? Ci.start : ""} ${r}`,
6300
+ className: `${Ti.truncate} ${t === "start" ? Ti.start : ""} ${r}`,
6238
6301
  title: i,
6239
6302
  children: t === "start" ? /* @__PURE__ */ h("bdi", { children: e }) : e
6240
6303
  });
6241
6304
  }
6242
- var Ti = {
6305
+ var Di = {
6243
6306
  disclosure: "_disclosure_94bgy_1",
6244
6307
  trigger: "_trigger_94bgy_7",
6245
6308
  summary: "_summary_94bgy_31",
@@ -6247,24 +6310,24 @@ var Ti = {
6247
6310
  content: "_content_94bgy_43"
6248
6311
  };
6249
6312
  // src/components/Disclosure/Disclosure.tsx
6250
- function Ei({ summary: t, children: n, open: r, defaultOpen: i = !1, onOpenChange: a, className: o = "" }) {
6313
+ function Oi({ summary: t, children: n, open: r, defaultOpen: i = !1, onOpenChange: a, className: o = "" }) {
6251
6314
  let [s, c] = e.useState(i), l = r ?? s, u = e.useId();
6252
6315
  return /* @__PURE__ */ g("div", {
6253
- className: `${Ti.disclosure} ${o}`,
6316
+ className: `${Di.disclosure} ${o}`,
6254
6317
  "data-state": l ? "open" : "closed",
6255
6318
  children: [/* @__PURE__ */ g("button", {
6256
6319
  type: "button",
6257
- className: Ti.trigger,
6320
+ className: Di.trigger,
6258
6321
  "aria-expanded": l,
6259
6322
  "aria-controls": l ? u : void 0,
6260
6323
  onClick: () => {
6261
6324
  r === void 0 && c(!l), a?.(!l);
6262
6325
  },
6263
6326
  children: [/* @__PURE__ */ h("span", {
6264
- className: Ti.summary,
6327
+ className: Di.summary,
6265
6328
  children: t
6266
6329
  }), /* @__PURE__ */ h("span", {
6267
- className: Ti.chevron,
6330
+ className: Di.chevron,
6268
6331
  "aria-hidden": "true",
6269
6332
  children: h(l ? x : C, {
6270
6333
  size: 14,
@@ -6273,18 +6336,18 @@ function Ei({ summary: t, children: n, open: r, defaultOpen: i = !1, onOpenChang
6273
6336
  })]
6274
6337
  }), l && /* @__PURE__ */ h("div", {
6275
6338
  id: u,
6276
- className: Ti.content,
6339
+ className: Di.content,
6277
6340
  children: n
6278
6341
  })]
6279
6342
  });
6280
6343
  }
6281
- var Di = {
6344
+ var ki = {
6282
6345
  field: "_field_5juos_1",
6283
6346
  code: "_code_5juos_16",
6284
6347
  status: "_status_5juos_31"
6285
6348
  };
6286
6349
  // src/components/CodeCopy/CodeCopy.tsx
6287
- async function Oi(e) {
6350
+ async function Ai(e) {
6288
6351
  if (navigator.clipboard && window.isSecureContext) try {
6289
6352
  return await navigator.clipboard.writeText(e), !0;
6290
6353
  } catch {}
@@ -6298,13 +6361,13 @@ async function Oi(e) {
6298
6361
  t.remove();
6299
6362
  }
6300
6363
  }
6301
- function ki({ code: e, className: t, onCopy: n }) {
6364
+ function ji({ code: e, className: t, onCopy: n }) {
6302
6365
  let [r, i] = f(!1), a = d(void 0);
6303
6366
  return o(() => () => clearTimeout(a.current), []), /* @__PURE__ */ g("div", {
6304
- className: [Di.field, t].filter(Boolean).join(" "),
6367
+ className: [ki.field, t].filter(Boolean).join(" "),
6305
6368
  children: [
6306
6369
  /* @__PURE__ */ h("code", {
6307
- className: Di.code,
6370
+ className: ki.code,
6308
6371
  children: e
6309
6372
  }),
6310
6373
  /* @__PURE__ */ h(W, {
@@ -6312,17 +6375,17 @@ function ki({ code: e, className: t, onCopy: n }) {
6312
6375
  variant: "ghost",
6313
6376
  iconLeft: h(r ? b : w, {}),
6314
6377
  onClick: async () => {
6315
- await Oi(e) && (i(!0), n?.(), clearTimeout(a.current), a.current = setTimeout(() => i(!1), 2e3));
6378
+ await Ai(e) && (i(!0), n?.(), clearTimeout(a.current), a.current = setTimeout(() => i(!1), 2e3));
6316
6379
  },
6317
6380
  "aria-label": r ? "Copied" : "Copy",
6318
6381
  title: r ? "Copied" : "Copy"
6319
6382
  }),
6320
6383
  /* @__PURE__ */ h("span", {
6321
- className: Di.status,
6384
+ className: ki.status,
6322
6385
  role: "status",
6323
6386
  children: r ? "Copied" : ""
6324
6387
  })
6325
6388
  ]
6326
6389
  });
6327
6390
  }
6328
- export { $n as Alert, tr as AlertDescription, er as AlertTitle, yi as AnswerActions, fi as AssistantMessage, xt as BarMeter, De as BarSlider, le as Base, ut as Breadcrumbs, W as Button, _r as Chart, ui as ChatPanel, se as Checkbox, Yn as Chip, gi as CitationList, hi as CitationRef, ki as CodeCopy, xn as Combobox, Zt as CommandPalette, mi as Composer, Mr as DatePicker, Ei as Disclosure, Cn as EmptyState, de as FilterPanelBase, qt as GroupedBars, At as Heatmap, Le as HistogramRange, Xr as Icicle, ge as InputField, Yt as Kbd, Tr as Modal, ti as NavigationMenu, oi as NavigationMenuContent, ri as NavigationMenuItem, si as NavigationMenuLink, ni as NavigationMenuList, ai as NavigationMenuTrigger, He as Popover, Ue as PopoverDivider, ie as PortalContainerProvider, ft as ProgressBar, Vt as RadarChart, Ft as RadialChart, ve as RadioButton, Si as Reasoning, An as Resizable, Lr as STAT_ICON_SIZE, rr as SaveBar, Wr as ScoreMeter, Ae as ScrubSlider, me as SearchField, st as SegmentedControl, ze as Select, Tn as Sheet, Vr as ShimmerText, vn as Sidebar, Fr as Skeleton, Se as Slider, Ne as SliderField, xr as Sparkline, ne as Spinner, Rr as Stat, zr as StatGroup, Kr as StepProgress, _i as StreamStatus, vi as Suggestions, Xe as Table, $e as TableCell, Ze as TableHeader, tt as TableIcon, Qe as TableRow, et as TableValue, at as Tabs, $t as TagsInput, Cr as Textarea, un as Toaster, be as ToggleSwitch, bi as ToolStep, xi as ToolSteps, fn as Tooltip, Gn as TreeCanvas, wi as Truncate, di as UserMessage, Et as Waffle, Tt as allocateCells, Ie as barsOf, Nt as calendarCells, li as defaultChatHints, kt as levelOf, U as spinnerNames, sn as toast, ae as usePortalContainer };
6391
+ export { $n as Alert, tr as AlertDescription, er as AlertTitle, yi as AnswerActions, fi as AssistantMessage, xt as BarMeter, De as BarSlider, le as Base, ut as Breadcrumbs, W as Button, _r as Chart, wi as ChatLauncher, ui as ChatPanel, se as Checkbox, Yn as Chip, gi as CitationList, hi as CitationRef, ji as CodeCopy, xn as Combobox, Zt as CommandPalette, mi as Composer, Mr as DatePicker, Oi as Disclosure, Cn as EmptyState, de as FilterPanelBase, qt as GroupedBars, At as Heatmap, Le as HistogramRange, Xr as Icicle, ge as InputField, Yt as Kbd, Tr as Modal, ti as NavigationMenu, oi as NavigationMenuContent, ri as NavigationMenuItem, si as NavigationMenuLink, ni as NavigationMenuList, ai as NavigationMenuTrigger, He as Popover, Ue as PopoverDivider, ie as PortalContainerProvider, ft as ProgressBar, Vt as RadarChart, Ft as RadialChart, ve as RadioButton, Si as Reasoning, An as Resizable, Lr as STAT_ICON_SIZE, rr as SaveBar, Wr as ScoreMeter, Ae as ScrubSlider, me as SearchField, st as SegmentedControl, ze as Select, Tn as Sheet, Vr as ShimmerText, vn as Sidebar, Fr as Skeleton, Se as Slider, Ne as SliderField, xr as Sparkline, ne as Spinner, Rr as Stat, zr as StatGroup, Kr as StepProgress, _i as StreamStatus, vi as Suggestions, Xe as Table, $e as TableCell, Ze as TableHeader, tt as TableIcon, Qe as TableRow, et as TableValue, at as Tabs, $t as TagsInput, Cr as Textarea, un as Toaster, be as ToggleSwitch, bi as ToolStep, xi as ToolSteps, fn as Tooltip, Gn as TreeCanvas, Ei as Truncate, di as UserMessage, Et as Waffle, Tt as allocateCells, Ie as barsOf, Nt as calendarCells, li as defaultChatHints, kt as levelOf, U as spinnerNames, sn as toast, ae as usePortalContainer };