@optilogic/chat 1.0.0-beta.12 → 1.0.0-beta.14
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 +7 -5
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.cts +5 -0
- package/dist/index.d.ts +5 -0
- package/dist/index.js +7 -5
- package/dist/index.js.map +1 -1
- package/package.json +3 -3
- package/src/components/agent-response/AgentResponse.tsx +9 -1
- package/src/components/agent-response/components/ThinkingSection.tsx +1 -1
- package/src/components/agent-timeline/AgentTimeline.tsx +2 -2
package/dist/index.d.cts
CHANGED
|
@@ -384,6 +384,11 @@ interface AgentResponseProps extends React.HTMLAttributes<HTMLDivElement> {
|
|
|
384
384
|
* />
|
|
385
385
|
*/
|
|
386
386
|
renderThinkingMarkdown?: (content: string) => React.ReactNode;
|
|
387
|
+
/**
|
|
388
|
+
* Maximum height of the AgentTimeline scrollable container.
|
|
389
|
+
* Defaults to "300px". Set to "none" to disable the constraint.
|
|
390
|
+
*/
|
|
391
|
+
timelineMaxHeight?: string;
|
|
387
392
|
}
|
|
388
393
|
/**
|
|
389
394
|
* AgentResponse Component
|
package/dist/index.d.ts
CHANGED
|
@@ -384,6 +384,11 @@ interface AgentResponseProps extends React.HTMLAttributes<HTMLDivElement> {
|
|
|
384
384
|
* />
|
|
385
385
|
*/
|
|
386
386
|
renderThinkingMarkdown?: (content: string) => React.ReactNode;
|
|
387
|
+
/**
|
|
388
|
+
* Maximum height of the AgentTimeline scrollable container.
|
|
389
|
+
* Defaults to "300px". Set to "none" to disable the constraint.
|
|
390
|
+
*/
|
|
391
|
+
timelineMaxHeight?: string;
|
|
387
392
|
}
|
|
388
393
|
/**
|
|
389
394
|
* AgentResponse Component
|
package/dist/index.js
CHANGED
|
@@ -234,7 +234,7 @@ var ThinkingSection = React11.forwardRef(
|
|
|
234
234
|
ref,
|
|
235
235
|
className: cn("px-3 pb-3 border-t border-border", className),
|
|
236
236
|
...props,
|
|
237
|
-
children: /* @__PURE__ */ jsx("div", { className: "mt-2 max-h-[200px] overflow-y-auto
|
|
237
|
+
children: /* @__PURE__ */ jsx("div", { className: "mt-2 max-h-[200px] overflow-y-auto", children: isStructured ? /* @__PURE__ */ jsx("div", { className: "space-y-0", children: content.map((step) => /* @__PURE__ */ jsx(
|
|
238
238
|
ThinkingStepItem,
|
|
239
239
|
{
|
|
240
240
|
step,
|
|
@@ -1224,10 +1224,10 @@ function AgentTimeline({ entries, renderMarkdown, uiState, maxHeight = "300px" }
|
|
|
1224
1224
|
"div",
|
|
1225
1225
|
{
|
|
1226
1226
|
ref: containerRef,
|
|
1227
|
-
className:
|
|
1227
|
+
className: maxHeight !== "none" ? "overflow-y-auto" : "",
|
|
1228
1228
|
style: scrollStyle,
|
|
1229
1229
|
children: [
|
|
1230
|
-
/* @__PURE__ */ jsxs("div", { className: "sticky top-0 z-10 bg-background flex items-center gap-1 py-1.5 mb-1 border-b border-border/50 flex-wrap", children: [
|
|
1230
|
+
/* @__PURE__ */ jsxs("div", { className: "sticky top-0 z-10 bg-background flex items-center gap-1 py-1.5 mb-1 border-b border-border/50 flex-wrap pl-2", children: [
|
|
1231
1231
|
TYPE_CONFIG.filter((tc) => availableTypes.has(tc.type)).map((tc) => {
|
|
1232
1232
|
const isActive = activeFilters.has(tc.type);
|
|
1233
1233
|
const count = entries.filter((e) => e.type === tc.type).length;
|
|
@@ -1323,6 +1323,7 @@ var AgentResponse = React11.forwardRef(
|
|
|
1323
1323
|
statusContent,
|
|
1324
1324
|
renderMarkdown,
|
|
1325
1325
|
renderThinkingMarkdown,
|
|
1326
|
+
timelineMaxHeight,
|
|
1326
1327
|
className,
|
|
1327
1328
|
...props
|
|
1328
1329
|
}, ref) => {
|
|
@@ -1384,12 +1385,13 @@ var AgentResponse = React11.forwardRef(
|
|
|
1384
1385
|
elapsedTime
|
|
1385
1386
|
}
|
|
1386
1387
|
),
|
|
1387
|
-
hasTimelineEntries ? thinkingExpanded && /* @__PURE__ */ jsx("div", { className: "
|
|
1388
|
+
hasTimelineEntries ? thinkingExpanded && /* @__PURE__ */ jsx("div", { className: "pb-3 border-t border-border", children: /* @__PURE__ */ jsx(
|
|
1388
1389
|
AgentTimeline,
|
|
1389
1390
|
{
|
|
1390
1391
|
entries: state.timelineEntries,
|
|
1391
1392
|
renderMarkdown: renderThinkingMarkdown,
|
|
1392
|
-
uiState: timelineUIStateRef.current
|
|
1393
|
+
uiState: timelineUIStateRef.current,
|
|
1394
|
+
maxHeight: timelineMaxHeight
|
|
1393
1395
|
}
|
|
1394
1396
|
) }) : /* @__PURE__ */ jsx(
|
|
1395
1397
|
ThinkingSection,
|