agentic-ui-libs 1.1.0-beta.2 → 1.1.0-beta.4
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/assets/agentic-ui-libs.css +11 -3
- package/dist/features/dashboard/Dashboard.d.ts.map +1 -1
- package/dist/features/tracing/components/TracesList.d.ts.map +1 -1
- package/dist/features/tracing/components/detail/DetailPage.d.ts.map +1 -1
- package/dist/features/tracing/components/detail/ObservationNode.d.ts.map +1 -1
- package/dist/features/tracing/components/detail/TraceTree.d.ts.map +1 -1
- package/dist/features/tracing/index.d.ts +1 -1
- package/dist/features/tracing/index.d.ts.map +1 -1
- package/dist/features/tracing/services/TracingApiService.d.ts +4 -0
- package/dist/features/tracing/services/TracingApiService.d.ts.map +1 -1
- package/dist/features/tracing/types.d.ts +14 -0
- package/dist/features/tracing/types.d.ts.map +1 -1
- package/dist/index.js +401 -369
- package/dist/shared/ui/daterangepicker.d.ts.map +1 -1
- package/dist/ui-libs.umd.js +401 -369
- package/package.json +1 -1
package/dist/index.js
CHANGED
|
@@ -4331,10 +4331,10 @@ const MetricCard = ({
|
|
|
4331
4331
|
className
|
|
4332
4332
|
),
|
|
4333
4333
|
onClick: handleClick2,
|
|
4334
|
-
"data-id": `dashboard_metric_card_${data.metricType || data.title.toLowerCase().replace(/\s+/g, "_")}`,
|
|
4334
|
+
"data-test-id": `dashboard_metric_card_${data.metricType || data.title.toLowerCase().replace(/\s+/g, "_")}`,
|
|
4335
4335
|
children: [
|
|
4336
|
-
/* @__PURE__ */ jsxRuntimeExports.jsxs("div", { className: "flex items-center gap-2 mb-[6px]", "data-id": `dashboard_metric_card_header_${data.metricType || data.title.toLowerCase().replace(/\s+/g, "_")}`, children: [
|
|
4337
|
-
/* @__PURE__ */ jsxRuntimeExports.jsx("span", { className: "text-sm font-medium text-gray-700", "data-id": `dashboard_metric_card_title_${data.metricType || data.title.toLowerCase().replace(/\s+/g, "_")}`, children: title }),
|
|
4336
|
+
/* @__PURE__ */ jsxRuntimeExports.jsxs("div", { className: "flex items-center gap-2 mb-[6px]", "data-test-id": `dashboard_metric_card_header_${data.metricType || data.title.toLowerCase().replace(/\s+/g, "_")}`, children: [
|
|
4337
|
+
/* @__PURE__ */ jsxRuntimeExports.jsx("span", { className: "text-sm font-medium text-gray-700", "data-test-id": `dashboard_metric_card_title_${data.metricType || data.title.toLowerCase().replace(/\s+/g, "_")}`, children: title }),
|
|
4338
4338
|
info && /* @__PURE__ */ jsxRuntimeExports.jsxs("div", { className: "relative group", children: [
|
|
4339
4339
|
/* @__PURE__ */ jsxRuntimeExports.jsx(Info, { className: "h-[16px] w-[16px] text-gray-400 cursor-help" }),
|
|
4340
4340
|
/* @__PURE__ */ jsxRuntimeExports.jsxs("div", { className: cn(
|
|
@@ -4352,8 +4352,8 @@ const MetricCard = ({
|
|
|
4352
4352
|
] })
|
|
4353
4353
|
] })
|
|
4354
4354
|
] }),
|
|
4355
|
-
/* @__PURE__ */ jsxRuntimeExports.jsxs("div", { className: "flex items-baseline gap-3", "data-id": `dashboard_metric_card_value_container_${data.metricType || data.title.toLowerCase().replace(/\s+/g, "_")}`, children: [
|
|
4356
|
-
/* @__PURE__ */ jsxRuntimeExports.jsx("span", { className: "text-2xl font-semibold text-gray-900", "data-id": `dashboard_metric_card_value_${data.metricType || data.title.toLowerCase().replace(/\s+/g, "_")}`, children: formatValue2(value) }),
|
|
4355
|
+
/* @__PURE__ */ jsxRuntimeExports.jsxs("div", { className: "flex items-baseline gap-3", "data-test-id": `dashboard_metric_card_value_container_${data.metricType || data.title.toLowerCase().replace(/\s+/g, "_")}`, children: [
|
|
4356
|
+
/* @__PURE__ */ jsxRuntimeExports.jsx("span", { className: "text-2xl font-semibold text-gray-900", "data-test-id": `dashboard_metric_card_value_${data.metricType || data.title.toLowerCase().replace(/\s+/g, "_")}`, children: formatValue2(value) }),
|
|
4357
4357
|
change && /* @__PURE__ */ jsxRuntimeExports.jsxs(
|
|
4358
4358
|
"div",
|
|
4359
4359
|
{
|
|
@@ -28966,8 +28966,8 @@ const AnalyticsChart = ({
|
|
|
28966
28966
|
console.log("Chart lines configuration:", chartLines);
|
|
28967
28967
|
console.log("Sample filled data points:", sortedData.slice(0, 3));
|
|
28968
28968
|
console.log("=== END ANALYTICS CHART DEBUG ===");
|
|
28969
|
-
return /* @__PURE__ */ jsxRuntimeExports.jsxs("div", { className: cn("w-full", className), "data-id": "dashboard_analytics_chart_root", children: [
|
|
28970
|
-
/* @__PURE__ */ jsxRuntimeExports.jsx("div", { className: "relative bg-gray-50/30", "data-id": "dashboard_analytics_chart_container", children: /* @__PURE__ */ jsxRuntimeExports.jsx(ResponsiveContainer, { width: "100%", height, "data-id": "dashboard_analytics_chart_responsive_container", children: /* @__PURE__ */ jsxRuntimeExports.jsxs(
|
|
28969
|
+
return /* @__PURE__ */ jsxRuntimeExports.jsxs("div", { className: cn("w-full", className), "data-test-id": "dashboard_analytics_chart_root", children: [
|
|
28970
|
+
/* @__PURE__ */ jsxRuntimeExports.jsx("div", { className: "relative bg-gray-50/30", "data-test-id": "dashboard_analytics_chart_container", children: /* @__PURE__ */ jsxRuntimeExports.jsx(ResponsiveContainer, { width: "100%", height, "data-test-id": "dashboard_analytics_chart_responsive_container", children: /* @__PURE__ */ jsxRuntimeExports.jsxs(
|
|
28971
28971
|
ComposedChart,
|
|
28972
28972
|
{
|
|
28973
28973
|
data: sortedData,
|
|
@@ -29066,10 +29066,10 @@ const AnalyticsChart = ({
|
|
|
29066
29066
|
]
|
|
29067
29067
|
}
|
|
29068
29068
|
) }) }),
|
|
29069
|
-
/* @__PURE__ */ jsxRuntimeExports.jsxs("div", { className: "mt-4 flex items-center justify-between", "data-id": "dashboard_analytics_chart_footer", children: [
|
|
29070
|
-
/* @__PURE__ */ jsxRuntimeExports.jsx("div", { "data-id": "dashboard_analytics_chart_date_range", children: dateRange && /* @__PURE__ */ jsxRuntimeExports.jsxs("p", { className: "text-xs text-gray-500 flex items-center gap-[4px]", "data-id": "dashboard_analytics_chart_date_range_text", children: [
|
|
29069
|
+
/* @__PURE__ */ jsxRuntimeExports.jsxs("div", { className: "mt-4 flex items-center justify-between", "data-test-id": "dashboard_analytics_chart_footer", children: [
|
|
29070
|
+
/* @__PURE__ */ jsxRuntimeExports.jsx("div", { "data-test-id": "dashboard_analytics_chart_date_range", children: dateRange && /* @__PURE__ */ jsxRuntimeExports.jsxs("p", { className: "text-xs text-gray-500 flex items-center gap-[4px]", "data-test-id": "dashboard_analytics_chart_date_range_text", children: [
|
|
29071
29071
|
/* @__PURE__ */ jsxRuntimeExports.jsx("span", { className: "text-gray-500", children: "Showing data from" }),
|
|
29072
|
-
/* @__PURE__ */ jsxRuntimeExports.jsxs("span", { className: "font-medium text-gray-700", "data-id": "dashboard_analytics_chart_date_range_value", children: [
|
|
29072
|
+
/* @__PURE__ */ jsxRuntimeExports.jsxs("span", { className: "font-medium text-gray-700", "data-test-id": "dashboard_analytics_chart_date_range_value", children: [
|
|
29073
29073
|
new Date(dateRange.start).toLocaleDateString("en-US", {
|
|
29074
29074
|
day: "numeric",
|
|
29075
29075
|
month: "short",
|
|
@@ -29083,16 +29083,16 @@ const AnalyticsChart = ({
|
|
|
29083
29083
|
})
|
|
29084
29084
|
] })
|
|
29085
29085
|
] }) }),
|
|
29086
|
-
/* @__PURE__ */ jsxRuntimeExports.jsx("div", { className: "flex items-center gap-4", "data-id": "dashboard_analytics_chart_legend", children: /* @__PURE__ */ jsxRuntimeExports.jsx("div", { className: "flex items-center gap-4 text-sm text-muted-foreground", "data-id": "dashboard_analytics_chart_legend_items", children: chartLines.map((lineConfig) => /* @__PURE__ */ jsxRuntimeExports.jsxs("div", { className: "flex items-center gap-2", "data-id": `dashboard_analytics_chart_legend_item_${lineConfig.dataKey}`, children: [
|
|
29086
|
+
/* @__PURE__ */ jsxRuntimeExports.jsx("div", { className: "flex items-center gap-4", "data-test-id": "dashboard_analytics_chart_legend", children: /* @__PURE__ */ jsxRuntimeExports.jsx("div", { className: "flex items-center gap-4 text-sm text-muted-foreground", "data-test-id": "dashboard_analytics_chart_legend_items", children: chartLines.map((lineConfig) => /* @__PURE__ */ jsxRuntimeExports.jsxs("div", { className: "flex items-center gap-2", "data-test-id": `dashboard_analytics_chart_legend_item_${lineConfig.dataKey}`, children: [
|
|
29087
29087
|
/* @__PURE__ */ jsxRuntimeExports.jsx(
|
|
29088
29088
|
"div",
|
|
29089
29089
|
{
|
|
29090
29090
|
className: "w-[8px] h-[8px] rounded-full",
|
|
29091
29091
|
style: { backgroundColor: lineConfig.color },
|
|
29092
|
-
"data-id": `dashboard_analytics_chart_legend_color_${lineConfig.dataKey}`
|
|
29092
|
+
"data-test-id": `dashboard_analytics_chart_legend_color_${lineConfig.dataKey}`
|
|
29093
29093
|
}
|
|
29094
29094
|
),
|
|
29095
|
-
/* @__PURE__ */ jsxRuntimeExports.jsx("span", { className: "text-xs text-gray-600", "data-id": `dashboard_analytics_chart_legend_label_${lineConfig.dataKey}`, children: lineConfig.label })
|
|
29095
|
+
/* @__PURE__ */ jsxRuntimeExports.jsx("span", { className: "text-xs text-gray-600", "data-test-id": `dashboard_analytics_chart_legend_label_${lineConfig.dataKey}`, children: lineConfig.label })
|
|
29096
29096
|
] }, lineConfig.dataKey)) }) })
|
|
29097
29097
|
] })
|
|
29098
29098
|
] });
|
|
@@ -29179,10 +29179,10 @@ const AnalyticsTable = ({
|
|
|
29179
29179
|
/* @__PURE__ */ jsxRuntimeExports.jsx(ChevronDown, { className: "w-[12px] h-[12px] opacity-30 -mt-1" })
|
|
29180
29180
|
] });
|
|
29181
29181
|
};
|
|
29182
|
-
return /* @__PURE__ */ jsxRuntimeExports.jsxs("div", { className: cn("w-full", className), "data-id": "dashboard_analytics_table_root", children: [
|
|
29183
|
-
/* @__PURE__ */ jsxRuntimeExports.jsxs("div", { className: "flex items-center justify-between mb-4", "data-id": "dashboard_analytics_table_header", children: [
|
|
29184
|
-
/* @__PURE__ */ jsxRuntimeExports.jsx("h3", { className: "text-md font-medium text-gray-700", "data-id": "dashboard_analytics_table_title", children: title }),
|
|
29185
|
-
filtering.enabled && filtering.searchable && /* @__PURE__ */ jsxRuntimeExports.jsxs("div", { className: "relative", "data-id": "dashboard_analytics_table_search", children: [
|
|
29182
|
+
return /* @__PURE__ */ jsxRuntimeExports.jsxs("div", { className: cn("w-full", className), "data-test-id": "dashboard_analytics_table_root", children: [
|
|
29183
|
+
/* @__PURE__ */ jsxRuntimeExports.jsxs("div", { className: "flex items-center justify-between mb-4", "data-test-id": "dashboard_analytics_table_header", children: [
|
|
29184
|
+
/* @__PURE__ */ jsxRuntimeExports.jsx("h3", { className: "text-md font-medium text-gray-700", "data-test-id": "dashboard_analytics_table_title", children: title }),
|
|
29185
|
+
filtering.enabled && filtering.searchable && /* @__PURE__ */ jsxRuntimeExports.jsxs("div", { className: "relative", "data-test-id": "dashboard_analytics_table_search", children: [
|
|
29186
29186
|
/* @__PURE__ */ jsxRuntimeExports.jsx(Search, { className: "absolute left-[12px] top-1/2 transform -translate-y-1/2 w-[16px] h-[16px] text-gray-400" }),
|
|
29187
29187
|
/* @__PURE__ */ jsxRuntimeExports.jsx(
|
|
29188
29188
|
"input",
|
|
@@ -29192,13 +29192,13 @@ const AnalyticsTable = ({
|
|
|
29192
29192
|
value: searchTerm,
|
|
29193
29193
|
onChange: (e3) => handleSearch(e3.target.value),
|
|
29194
29194
|
className: "pl-[36px] pr-[12px] py-[8px] border border-gray-200 rounded-lg text-xs focus:outline-none focus:ring-2 focus:ring-blue-500 focus:border-transparent",
|
|
29195
|
-
"data-id": "dashboard_analytics_table_search_input"
|
|
29195
|
+
"data-test-id": "dashboard_analytics_table_search_input"
|
|
29196
29196
|
}
|
|
29197
29197
|
)
|
|
29198
29198
|
] })
|
|
29199
29199
|
] }),
|
|
29200
|
-
/* @__PURE__ */ jsxRuntimeExports.jsx("div", { className: "overflow-x-auto border border-gray-200 rounded-lg", "data-id": "dashboard_analytics_table_wrapper", children: /* @__PURE__ */ jsxRuntimeExports.jsxs("table", { className: "w-full", "data-id": "dashboard_analytics_table", children: [
|
|
29201
|
-
/* @__PURE__ */ jsxRuntimeExports.jsx("thead", { className: "bg-gray-50", "data-id": "dashboard_analytics_table_head", children: /* @__PURE__ */ jsxRuntimeExports.jsx("tr", { "data-id": "dashboard_analytics_table_head_row", children: columns.map((column) => /* @__PURE__ */ jsxRuntimeExports.jsx(
|
|
29200
|
+
/* @__PURE__ */ jsxRuntimeExports.jsx("div", { className: "overflow-x-auto border border-gray-200 rounded-lg", "data-test-id": "dashboard_analytics_table_wrapper", children: /* @__PURE__ */ jsxRuntimeExports.jsxs("table", { className: "w-full", "data-test-id": "dashboard_analytics_table", children: [
|
|
29201
|
+
/* @__PURE__ */ jsxRuntimeExports.jsx("thead", { className: "bg-gray-50", "data-test-id": "dashboard_analytics_table_head", children: /* @__PURE__ */ jsxRuntimeExports.jsx("tr", { "data-test-id": "dashboard_analytics_table_head_row", children: columns.map((column) => /* @__PURE__ */ jsxRuntimeExports.jsx(
|
|
29202
29202
|
"th",
|
|
29203
29203
|
{
|
|
29204
29204
|
className: cn(
|
|
@@ -29209,19 +29209,19 @@ const AnalyticsTable = ({
|
|
|
29209
29209
|
),
|
|
29210
29210
|
style: { width: column.width },
|
|
29211
29211
|
onClick: () => handleSort(column),
|
|
29212
|
-
"data-id": `dashboard_analytics_table_header_${column.key}`,
|
|
29213
|
-
children: /* @__PURE__ */ jsxRuntimeExports.jsxs("div", { className: "flex items-center gap-2", "data-id": `dashboard_analytics_table_header_content_${column.key}`, children: [
|
|
29212
|
+
"data-test-id": `dashboard_analytics_table_header_${column.key}`,
|
|
29213
|
+
children: /* @__PURE__ */ jsxRuntimeExports.jsxs("div", { className: "flex items-center gap-2", "data-test-id": `dashboard_analytics_table_header_content_${column.key}`, children: [
|
|
29214
29214
|
/* @__PURE__ */ jsxRuntimeExports.jsx("span", { children: column.title }),
|
|
29215
29215
|
getSortIcon(column)
|
|
29216
29216
|
] })
|
|
29217
29217
|
},
|
|
29218
29218
|
column.key
|
|
29219
29219
|
)) }) }),
|
|
29220
|
-
/* @__PURE__ */ jsxRuntimeExports.jsx("tbody", { className: "bg-white divide-y divide-gray-200", "data-id": "dashboard_analytics_table_body", children: paginatedData.map((row, rowIndex) => /* @__PURE__ */ jsxRuntimeExports.jsx(
|
|
29220
|
+
/* @__PURE__ */ jsxRuntimeExports.jsx("tbody", { className: "bg-white divide-y divide-gray-200", "data-test-id": "dashboard_analytics_table_body", children: paginatedData.map((row, rowIndex) => /* @__PURE__ */ jsxRuntimeExports.jsx(
|
|
29221
29221
|
"tr",
|
|
29222
29222
|
{
|
|
29223
29223
|
className: "hover:bg-gray-50 transition-colors",
|
|
29224
|
-
"data-id": `dashboard_analytics_table_row_${rowIndex}`,
|
|
29224
|
+
"data-test-id": `dashboard_analytics_table_row_${rowIndex}`,
|
|
29225
29225
|
children: columns.map((column) => /* @__PURE__ */ jsxRuntimeExports.jsx(
|
|
29226
29226
|
"td",
|
|
29227
29227
|
{
|
|
@@ -29230,7 +29230,7 @@ const AnalyticsTable = ({
|
|
|
29230
29230
|
column.align === "center" && "text-center",
|
|
29231
29231
|
column.align === "right" && "text-right"
|
|
29232
29232
|
),
|
|
29233
|
-
"data-id": `dashboard_analytics_table_cell_${rowIndex}_${column.key}`,
|
|
29233
|
+
"data-test-id": `dashboard_analytics_table_cell_${rowIndex}_${column.key}`,
|
|
29234
29234
|
children: formatCellValue(row[column.key], column, row)
|
|
29235
29235
|
},
|
|
29236
29236
|
column.key
|
|
@@ -29239,8 +29239,8 @@ const AnalyticsTable = ({
|
|
|
29239
29239
|
rowIndex
|
|
29240
29240
|
)) })
|
|
29241
29241
|
] }) }),
|
|
29242
|
-
pagination.enabled && totalPages > 1 && /* @__PURE__ */ jsxRuntimeExports.jsxs("div", { className: "flex items-center justify-between mt-4", "data-id": "dashboard_analytics_table_pagination", children: [
|
|
29243
|
-
/* @__PURE__ */ jsxRuntimeExports.jsxs("div", { className: "text-xs text-gray-500", "data-id": "dashboard_analytics_table_pagination_info", children: [
|
|
29242
|
+
pagination.enabled && totalPages > 1 && /* @__PURE__ */ jsxRuntimeExports.jsxs("div", { className: "flex items-center justify-between mt-4", "data-test-id": "dashboard_analytics_table_pagination", children: [
|
|
29243
|
+
/* @__PURE__ */ jsxRuntimeExports.jsxs("div", { className: "text-xs text-gray-500", "data-test-id": "dashboard_analytics_table_pagination_info", children: [
|
|
29244
29244
|
"Showing ",
|
|
29245
29245
|
(currentPage - 1) * pagination.pageSize + 1,
|
|
29246
29246
|
" to",
|
|
@@ -29251,14 +29251,14 @@ const AnalyticsTable = ({
|
|
|
29251
29251
|
processedData.length,
|
|
29252
29252
|
" results"
|
|
29253
29253
|
] }),
|
|
29254
|
-
/* @__PURE__ */ jsxRuntimeExports.jsxs("div", { className: "flex items-center gap-2", "data-id": "dashboard_analytics_table_pagination_controls", children: [
|
|
29254
|
+
/* @__PURE__ */ jsxRuntimeExports.jsxs("div", { className: "flex items-center gap-2", "data-test-id": "dashboard_analytics_table_pagination_controls", children: [
|
|
29255
29255
|
/* @__PURE__ */ jsxRuntimeExports.jsx(
|
|
29256
29256
|
"button",
|
|
29257
29257
|
{
|
|
29258
29258
|
onClick: () => setCurrentPage((prev) => Math.max(1, prev - 1)),
|
|
29259
29259
|
disabled: currentPage === 1,
|
|
29260
29260
|
className: "px-[12px] py-[4px] text-xs border border-gray-200 rounded hover:bg-gray-50 disabled:opacity-50 disabled:cursor-not-allowed",
|
|
29261
|
-
"data-id": "dashboard_analytics_table_pagination_btn_previous",
|
|
29261
|
+
"data-test-id": "dashboard_analytics_table_pagination_btn_previous",
|
|
29262
29262
|
children: "Previous"
|
|
29263
29263
|
}
|
|
29264
29264
|
),
|
|
@@ -29276,7 +29276,7 @@ const AnalyticsTable = ({
|
|
|
29276
29276
|
"px-[12px] py-[4px] text-xs border rounded",
|
|
29277
29277
|
currentPage === pageNum ? "bg-blue-500 text-white border-blue-500" : "border-gray-200 hover:bg-gray-50"
|
|
29278
29278
|
),
|
|
29279
|
-
"data-id": `dashboard_analytics_table_pagination_btn_page_${pageNum}`,
|
|
29279
|
+
"data-test-id": `dashboard_analytics_table_pagination_btn_page_${pageNum}`,
|
|
29280
29280
|
children: pageNum
|
|
29281
29281
|
},
|
|
29282
29282
|
pageNum
|
|
@@ -29288,13 +29288,13 @@ const AnalyticsTable = ({
|
|
|
29288
29288
|
onClick: () => setCurrentPage((prev) => Math.min(totalPages, prev + 1)),
|
|
29289
29289
|
disabled: currentPage === totalPages,
|
|
29290
29290
|
className: "px-[12px] py-[4px] text-xs border border-gray-200 rounded hover:bg-gray-50 disabled:opacity-50 disabled:cursor-not-allowed",
|
|
29291
|
-
"data-id": "dashboard_analytics_table_pagination_btn_next",
|
|
29291
|
+
"data-test-id": "dashboard_analytics_table_pagination_btn_next",
|
|
29292
29292
|
children: "Next"
|
|
29293
29293
|
}
|
|
29294
29294
|
)
|
|
29295
29295
|
] })
|
|
29296
29296
|
] }),
|
|
29297
|
-
paginatedData.length === 0 && /* @__PURE__ */ jsxRuntimeExports.jsx("div", { className: "text-center py-[32px] text-gray-500", "data-id": "dashboard_analytics_table_empty_state", children: searchTerm ? "No results found for your search." : "No data available." })
|
|
29297
|
+
paginatedData.length === 0 && /* @__PURE__ */ jsxRuntimeExports.jsx("div", { className: "text-center py-[32px] text-gray-500", "data-test-id": "dashboard_analytics_table_empty_state", children: searchTerm ? "No results found for your search." : "No data available." })
|
|
29298
29298
|
] });
|
|
29299
29299
|
};
|
|
29300
29300
|
const ASSETS_DOMAIN = "https://staging-agent-platform.kore.ai";
|
|
@@ -29588,21 +29588,21 @@ const AgentListView = ({
|
|
|
29588
29588
|
}
|
|
29589
29589
|
return value.toString();
|
|
29590
29590
|
};
|
|
29591
|
-
return /* @__PURE__ */ jsxRuntimeExports.jsxs("div", { className: cn("w-full", className), "data-id": "dashboard_agent_list_view_root", children: [
|
|
29592
|
-
/* @__PURE__ */ jsxRuntimeExports.jsxs("div", { className: "grid grid-cols-4 items-center gap-4 px-[16px] py-[12px] bg-gray-50 border-b border-gray-200 text-xs font-medium text-gray-600", "data-id": "dashboard_agent_list_view_header", children: [
|
|
29593
|
-
/* @__PURE__ */ jsxRuntimeExports.jsx("div", { className: "text-left", "data-id": "dashboard_agent_list_view_header_name", children: "Name" }),
|
|
29594
|
-
/* @__PURE__ */ jsxRuntimeExports.jsx("div", { className: "text-center", "data-id": "dashboard_agent_list_view_header_runs", children: "Runs" }),
|
|
29595
|
-
/* @__PURE__ */ jsxRuntimeExports.jsx("div", { className: "text-center", "data-id": "dashboard_agent_list_view_header_response_time", children: "Response Time" }),
|
|
29596
|
-
/* @__PURE__ */ jsxRuntimeExports.jsx("div", { className: "text-center", "data-id": "dashboard_agent_list_view_header_tokens", children: "Tokens" })
|
|
29591
|
+
return /* @__PURE__ */ jsxRuntimeExports.jsxs("div", { className: cn("w-full", className), "data-test-id": "dashboard_agent_list_view_root", children: [
|
|
29592
|
+
/* @__PURE__ */ jsxRuntimeExports.jsxs("div", { className: "grid grid-cols-4 items-center gap-4 px-[16px] py-[12px] bg-gray-50 border-b border-gray-200 text-xs font-medium text-gray-600", "data-test-id": "dashboard_agent_list_view_header", children: [
|
|
29593
|
+
/* @__PURE__ */ jsxRuntimeExports.jsx("div", { className: "text-left", "data-test-id": "dashboard_agent_list_view_header_name", children: "Name" }),
|
|
29594
|
+
/* @__PURE__ */ jsxRuntimeExports.jsx("div", { className: "text-center", "data-test-id": "dashboard_agent_list_view_header_runs", children: "Runs" }),
|
|
29595
|
+
/* @__PURE__ */ jsxRuntimeExports.jsx("div", { className: "text-center", "data-test-id": "dashboard_agent_list_view_header_response_time", children: "Response Time" }),
|
|
29596
|
+
/* @__PURE__ */ jsxRuntimeExports.jsx("div", { className: "text-center", "data-test-id": "dashboard_agent_list_view_header_tokens", children: "Tokens" })
|
|
29597
29597
|
] }),
|
|
29598
|
-
/* @__PURE__ */ jsxRuntimeExports.jsx("div", { className: "divide-y divide-gray-100", "data-id": "dashboard_agent_list_view_body", children: data.slice(0, visibleCount).map((agent2, index) => /* @__PURE__ */ jsxRuntimeExports.jsxs(
|
|
29598
|
+
/* @__PURE__ */ jsxRuntimeExports.jsx("div", { className: "divide-y divide-gray-100", "data-test-id": "dashboard_agent_list_view_body", children: data.slice(0, visibleCount).map((agent2, index) => /* @__PURE__ */ jsxRuntimeExports.jsxs(
|
|
29599
29599
|
"div",
|
|
29600
29600
|
{
|
|
29601
29601
|
className: "grid grid-cols-4 items-center gap-4 px-[16px] py-[12px] cursor-pointer transition-colors duration-150 border-b border-gray-200",
|
|
29602
|
-
"data-id": `dashboard_agent_list_view_row_${index}`,
|
|
29602
|
+
"data-test-id": `dashboard_agent_list_view_row_${index}`,
|
|
29603
29603
|
children: [
|
|
29604
|
-
/* @__PURE__ */ jsxRuntimeExports.jsxs("div", { className: "flex items-center gap-[8px]", "data-id": `dashboard_agent_list_view_row_name_${index}`, children: [
|
|
29605
|
-
/* @__PURE__ */ jsxRuntimeExports.jsx("div", { className: "flex-shrink-0", "data-id": `dashboard_agent_list_view_row_avatar_${index}`, children: /* @__PURE__ */ jsxRuntimeExports.jsx(
|
|
29604
|
+
/* @__PURE__ */ jsxRuntimeExports.jsxs("div", { className: "flex items-center gap-[8px]", "data-test-id": `dashboard_agent_list_view_row_name_${index}`, children: [
|
|
29605
|
+
/* @__PURE__ */ jsxRuntimeExports.jsx("div", { className: "flex-shrink-0", "data-test-id": `dashboard_agent_list_view_row_avatar_${index}`, children: /* @__PURE__ */ jsxRuntimeExports.jsx(
|
|
29606
29606
|
IconPreview,
|
|
29607
29607
|
{
|
|
29608
29608
|
icon: agent2.icon,
|
|
@@ -29611,21 +29611,21 @@ const AgentListView = ({
|
|
|
29611
29611
|
name: agent2.name || "Unknown Agent"
|
|
29612
29612
|
}
|
|
29613
29613
|
) }),
|
|
29614
|
-
/* @__PURE__ */ jsxRuntimeExports.jsx("div", { className: "min-w-0 flex-1 w-full", "data-id": `dashboard_agent_list_view_row_name_text_${index}`, children: /* @__PURE__ */ jsxRuntimeExports.jsx("div", { className: "text-xs font-medium text-gray-700 truncate", children: agent2.name || "Unknown Agent" }) })
|
|
29614
|
+
/* @__PURE__ */ jsxRuntimeExports.jsx("div", { className: "min-w-0 flex-1 w-full", "data-test-id": `dashboard_agent_list_view_row_name_text_${index}`, children: /* @__PURE__ */ jsxRuntimeExports.jsx("div", { className: "text-xs font-medium text-gray-700 truncate", children: agent2.name || "Unknown Agent" }) })
|
|
29615
29615
|
] }),
|
|
29616
|
-
/* @__PURE__ */ jsxRuntimeExports.jsx("div", { className: "text-center font-medium text-xs text-gray-700", "data-id": `dashboard_agent_list_view_row_runs_${index}`, children: agent2.runs ? formatValue2(agent2.runs) : "-" }),
|
|
29617
|
-
/* @__PURE__ */ jsxRuntimeExports.jsx("div", { className: "text-center font-medium text-xs text-gray-700", "data-id": `dashboard_agent_list_view_row_response_time_${index}`, children: agent2.responseTime || "-" }),
|
|
29618
|
-
/* @__PURE__ */ jsxRuntimeExports.jsx("div", { className: "text-center font-medium text-xs text-gray-700", "data-id": `dashboard_agent_list_view_row_tokens_${index}`, children: agent2.tokens ? formatValue2(agent2.tokens) : "-" })
|
|
29616
|
+
/* @__PURE__ */ jsxRuntimeExports.jsx("div", { className: "text-center font-medium text-xs text-gray-700", "data-test-id": `dashboard_agent_list_view_row_runs_${index}`, children: agent2.runs ? formatValue2(agent2.runs) : "-" }),
|
|
29617
|
+
/* @__PURE__ */ jsxRuntimeExports.jsx("div", { className: "text-center font-medium text-xs text-gray-700", "data-test-id": `dashboard_agent_list_view_row_response_time_${index}`, children: agent2.responseTime || "-" }),
|
|
29618
|
+
/* @__PURE__ */ jsxRuntimeExports.jsx("div", { className: "text-center font-medium text-xs text-gray-700", "data-test-id": `dashboard_agent_list_view_row_tokens_${index}`, children: agent2.tokens ? formatValue2(agent2.tokens) : "-" })
|
|
29619
29619
|
]
|
|
29620
29620
|
},
|
|
29621
29621
|
agent2.id || index
|
|
29622
29622
|
)) }),
|
|
29623
|
-
visibleCount < data.length && /* @__PURE__ */ jsxRuntimeExports.jsx("div", { className: "flex justify-center", "data-id": "dashboard_agent_list_view_load_more_container", children: /* @__PURE__ */ jsxRuntimeExports.jsx(
|
|
29623
|
+
visibleCount < data.length && /* @__PURE__ */ jsxRuntimeExports.jsx("div", { className: "flex justify-center", "data-test-id": "dashboard_agent_list_view_load_more_container", children: /* @__PURE__ */ jsxRuntimeExports.jsx(
|
|
29624
29624
|
"button",
|
|
29625
29625
|
{
|
|
29626
29626
|
onClick: loadMore,
|
|
29627
29627
|
className: "px-[16px] py-[8px] text-xs font-medium text-gray-700 bg-white border border-gray-300 rounded-md hover:bg-gray-50 transition-colors duration-150",
|
|
29628
|
-
"data-id": "dashboard_agent_list_view_load_more_btn",
|
|
29628
|
+
"data-test-id": "dashboard_agent_list_view_load_more_btn",
|
|
29629
29629
|
children: "Load 10 more"
|
|
29630
29630
|
}
|
|
29631
29631
|
) })
|
|
@@ -29669,21 +29669,21 @@ const ToolListView = ({
|
|
|
29669
29669
|
}
|
|
29670
29670
|
return value.toString();
|
|
29671
29671
|
};
|
|
29672
|
-
return /* @__PURE__ */ jsxRuntimeExports.jsxs("div", { className: cn("w-full", className), "data-id": "dashboard_tool_list_view_root", children: [
|
|
29673
|
-
/* @__PURE__ */ jsxRuntimeExports.jsxs("div", { className: "grid grid-cols-4 items-center gap-4 px-[16px] py-[12px] bg-gray-50 border-b border-gray-200 text-xs font-medium text-gray-600", "data-id": "dashboard_tool_list_view_header", children: [
|
|
29674
|
-
/* @__PURE__ */ jsxRuntimeExports.jsx("div", { className: "text-left", "data-id": "dashboard_tool_list_view_header_name", children: "Name" }),
|
|
29675
|
-
/* @__PURE__ */ jsxRuntimeExports.jsx("div", { className: "text-center", "data-id": "dashboard_tool_list_view_header_type", children: "Type" }),
|
|
29676
|
-
/* @__PURE__ */ jsxRuntimeExports.jsx("div", { className: "text-center", "data-id": "dashboard_tool_list_view_header_runs", children: "Runs" }),
|
|
29677
|
-
/* @__PURE__ */ jsxRuntimeExports.jsx("div", { className: "text-center", "data-id": "dashboard_tool_list_view_header_response_time", children: "Response Time" })
|
|
29672
|
+
return /* @__PURE__ */ jsxRuntimeExports.jsxs("div", { className: cn("w-full", className), "data-test-id": "dashboard_tool_list_view_root", children: [
|
|
29673
|
+
/* @__PURE__ */ jsxRuntimeExports.jsxs("div", { className: "grid grid-cols-4 items-center gap-4 px-[16px] py-[12px] bg-gray-50 border-b border-gray-200 text-xs font-medium text-gray-600", "data-test-id": "dashboard_tool_list_view_header", children: [
|
|
29674
|
+
/* @__PURE__ */ jsxRuntimeExports.jsx("div", { className: "text-left", "data-test-id": "dashboard_tool_list_view_header_name", children: "Name" }),
|
|
29675
|
+
/* @__PURE__ */ jsxRuntimeExports.jsx("div", { className: "text-center", "data-test-id": "dashboard_tool_list_view_header_type", children: "Type" }),
|
|
29676
|
+
/* @__PURE__ */ jsxRuntimeExports.jsx("div", { className: "text-center", "data-test-id": "dashboard_tool_list_view_header_runs", children: "Runs" }),
|
|
29677
|
+
/* @__PURE__ */ jsxRuntimeExports.jsx("div", { className: "text-center", "data-test-id": "dashboard_tool_list_view_header_response_time", children: "Response Time" })
|
|
29678
29678
|
] }),
|
|
29679
|
-
/* @__PURE__ */ jsxRuntimeExports.jsx("div", { className: "divide-y divide-gray-100", "data-id": "dashboard_tool_list_view_body", children: data.slice(0, visibleCount).map((tool, index) => /* @__PURE__ */ jsxRuntimeExports.jsxs(
|
|
29679
|
+
/* @__PURE__ */ jsxRuntimeExports.jsx("div", { className: "divide-y divide-gray-100", "data-test-id": "dashboard_tool_list_view_body", children: data.slice(0, visibleCount).map((tool, index) => /* @__PURE__ */ jsxRuntimeExports.jsxs(
|
|
29680
29680
|
"div",
|
|
29681
29681
|
{
|
|
29682
29682
|
className: "grid grid-cols-4 items-center gap-4 px-[16px] py-[12px] cursor-pointer transition-colors duration-150 border-b border-gray-200",
|
|
29683
|
-
"data-id": `dashboard_tool_list_view_row_${index}`,
|
|
29683
|
+
"data-test-id": `dashboard_tool_list_view_row_${index}`,
|
|
29684
29684
|
children: [
|
|
29685
|
-
/* @__PURE__ */ jsxRuntimeExports.jsxs("div", { className: "flex items-center gap-[8px]", "data-id": `dashboard_tool_list_view_row_name_${index}`, children: [
|
|
29686
|
-
/* @__PURE__ */ jsxRuntimeExports.jsx("div", { className: "flex-shrink-0", "data-id": `dashboard_tool_list_view_row_icon_${index}`, children: /* @__PURE__ */ jsxRuntimeExports.jsx(
|
|
29685
|
+
/* @__PURE__ */ jsxRuntimeExports.jsxs("div", { className: "flex items-center gap-[8px]", "data-test-id": `dashboard_tool_list_view_row_name_${index}`, children: [
|
|
29686
|
+
/* @__PURE__ */ jsxRuntimeExports.jsx("div", { className: "flex-shrink-0", "data-test-id": `dashboard_tool_list_view_row_icon_${index}`, children: /* @__PURE__ */ jsxRuntimeExports.jsx(
|
|
29687
29687
|
IconPreview,
|
|
29688
29688
|
{
|
|
29689
29689
|
icon: tool.icon,
|
|
@@ -29693,24 +29693,24 @@ const ToolListView = ({
|
|
|
29693
29693
|
toolType: tool["toolType"] || tool["type"]
|
|
29694
29694
|
}
|
|
29695
29695
|
) }),
|
|
29696
|
-
/* @__PURE__ */ jsxRuntimeExports.jsx("div", { className: "min-w-0 flex-1 w-full", "data-id": `dashboard_tool_list_view_row_name_text_${index}`, children: /* @__PURE__ */ jsxRuntimeExports.jsx("div", { className: "text-xs font-medium text-gray-700 truncate", children: tool.name || "Unknown Tool" }) })
|
|
29696
|
+
/* @__PURE__ */ jsxRuntimeExports.jsx("div", { className: "min-w-0 flex-1 w-full", "data-test-id": `dashboard_tool_list_view_row_name_text_${index}`, children: /* @__PURE__ */ jsxRuntimeExports.jsx("div", { className: "text-xs font-medium text-gray-700 truncate", children: tool.name || "Unknown Tool" }) })
|
|
29697
29697
|
] }),
|
|
29698
|
-
/* @__PURE__ */ jsxRuntimeExports.jsx("div", { className: "flex items-center justify-center", "data-id": `dashboard_tool_list_view_row_type_${index}`, children: /* @__PURE__ */ jsxRuntimeExports.jsx("span", { className: cn(
|
|
29698
|
+
/* @__PURE__ */ jsxRuntimeExports.jsx("div", { className: "flex items-center justify-center", "data-test-id": `dashboard_tool_list_view_row_type_${index}`, children: /* @__PURE__ */ jsxRuntimeExports.jsx("span", { className: cn(
|
|
29699
29699
|
"inline-flex items-center px-[10px] py-[4px] rounded-full text-xs font-medium border",
|
|
29700
29700
|
getToolTypeStyle(tool["toolType"] || tool["type"] || "Default")
|
|
29701
|
-
), "data-id": `dashboard_tool_list_view_row_type_badge_${index}`, children: getToolTypeName(tool["toolType"] || tool["type"] || "Default") }) }),
|
|
29702
|
-
/* @__PURE__ */ jsxRuntimeExports.jsx("div", { className: "text-center font-medium text-xs text-gray-700", "data-id": `dashboard_tool_list_view_row_runs_${index}`, children: tool.runs ? formatValue2(tool.runs) : "-" }),
|
|
29703
|
-
/* @__PURE__ */ jsxRuntimeExports.jsx("div", { className: "text-center font-medium text-xs text-gray-700", "data-id": `dashboard_tool_list_view_row_response_time_${index}`, children: tool.responseTime || "-" })
|
|
29701
|
+
), "data-test-id": `dashboard_tool_list_view_row_type_badge_${index}`, children: getToolTypeName(tool["toolType"] || tool["type"] || "Default") }) }),
|
|
29702
|
+
/* @__PURE__ */ jsxRuntimeExports.jsx("div", { className: "text-center font-medium text-xs text-gray-700", "data-test-id": `dashboard_tool_list_view_row_runs_${index}`, children: tool.runs ? formatValue2(tool.runs) : "-" }),
|
|
29703
|
+
/* @__PURE__ */ jsxRuntimeExports.jsx("div", { className: "text-center font-medium text-xs text-gray-700", "data-test-id": `dashboard_tool_list_view_row_response_time_${index}`, children: tool.responseTime || "-" })
|
|
29704
29704
|
]
|
|
29705
29705
|
},
|
|
29706
29706
|
tool.id || index
|
|
29707
29707
|
)) }),
|
|
29708
|
-
visibleCount < data.length && /* @__PURE__ */ jsxRuntimeExports.jsx("div", { className: "flex justify-center", "data-id": "dashboard_tool_list_view_load_more_container", children: /* @__PURE__ */ jsxRuntimeExports.jsx(
|
|
29708
|
+
visibleCount < data.length && /* @__PURE__ */ jsxRuntimeExports.jsx("div", { className: "flex justify-center", "data-test-id": "dashboard_tool_list_view_load_more_container", children: /* @__PURE__ */ jsxRuntimeExports.jsx(
|
|
29709
29709
|
"button",
|
|
29710
29710
|
{
|
|
29711
29711
|
onClick: loadMore,
|
|
29712
29712
|
className: "px-[16px] py-[8px] text-xs font-medium text-gray-700 bg-white border border-gray-300 rounded-md hover:bg-gray-50 transition-colors duration-150",
|
|
29713
|
-
"data-id": "dashboard_tool_list_view_load_more_btn",
|
|
29713
|
+
"data-test-id": "dashboard_tool_list_view_load_more_btn",
|
|
29714
29714
|
children: "Load 10 more"
|
|
29715
29715
|
}
|
|
29716
29716
|
) })
|
|
@@ -29850,44 +29850,44 @@ const ModelListView = ({
|
|
|
29850
29850
|
}
|
|
29851
29851
|
return value.toString();
|
|
29852
29852
|
};
|
|
29853
|
-
return /* @__PURE__ */ jsxRuntimeExports.jsxs("div", { className: cn("w-full", className), "data-id": "dashboard_model_list_view_root", children: [
|
|
29854
|
-
/* @__PURE__ */ jsxRuntimeExports.jsxs("div", { className: "grid grid-cols-4 items-center gap-4 px-[16px] py-[12px] bg-gray-50 border-b border-gray-200 text-xs font-medium text-gray-600", "data-id": "dashboard_model_list_view_header", children: [
|
|
29855
|
-
/* @__PURE__ */ jsxRuntimeExports.jsx("div", { className: "text-left", "data-id": "dashboard_model_list_view_header_name", children: "Model Name" }),
|
|
29856
|
-
/* @__PURE__ */ jsxRuntimeExports.jsx("div", { className: "text-center", "data-id": "dashboard_model_list_view_header_runs", children: "Runs" }),
|
|
29857
|
-
/* @__PURE__ */ jsxRuntimeExports.jsx("div", { className: "text-center", "data-id": "dashboard_model_list_view_header_tokens", children: "Tokens" }),
|
|
29858
|
-
/* @__PURE__ */ jsxRuntimeExports.jsx("div", { className: "text-center", "data-id": "dashboard_model_list_view_header_response_time", children: "Response Time" })
|
|
29853
|
+
return /* @__PURE__ */ jsxRuntimeExports.jsxs("div", { className: cn("w-full", className), "data-test-id": "dashboard_model_list_view_root", children: [
|
|
29854
|
+
/* @__PURE__ */ jsxRuntimeExports.jsxs("div", { className: "grid grid-cols-4 items-center gap-4 px-[16px] py-[12px] bg-gray-50 border-b border-gray-200 text-xs font-medium text-gray-600", "data-test-id": "dashboard_model_list_view_header", children: [
|
|
29855
|
+
/* @__PURE__ */ jsxRuntimeExports.jsx("div", { className: "text-left", "data-test-id": "dashboard_model_list_view_header_name", children: "Model Name" }),
|
|
29856
|
+
/* @__PURE__ */ jsxRuntimeExports.jsx("div", { className: "text-center", "data-test-id": "dashboard_model_list_view_header_runs", children: "Runs" }),
|
|
29857
|
+
/* @__PURE__ */ jsxRuntimeExports.jsx("div", { className: "text-center", "data-test-id": "dashboard_model_list_view_header_tokens", children: "Tokens" }),
|
|
29858
|
+
/* @__PURE__ */ jsxRuntimeExports.jsx("div", { className: "text-center", "data-test-id": "dashboard_model_list_view_header_response_time", children: "Response Time" })
|
|
29859
29859
|
] }),
|
|
29860
|
-
/* @__PURE__ */ jsxRuntimeExports.jsx("div", { className: "divide-y divide-gray-100", "data-id": "dashboard_model_list_view_body", children: data.slice(0, visibleCount).map((model, index) => /* @__PURE__ */ jsxRuntimeExports.jsxs(
|
|
29860
|
+
/* @__PURE__ */ jsxRuntimeExports.jsx("div", { className: "divide-y divide-gray-100", "data-test-id": "dashboard_model_list_view_body", children: data.slice(0, visibleCount).map((model, index) => /* @__PURE__ */ jsxRuntimeExports.jsxs(
|
|
29861
29861
|
"div",
|
|
29862
29862
|
{
|
|
29863
29863
|
className: "grid grid-cols-4 items-center gap-4 px-[16px] py-[12px] cursor-pointer transition-colors duration-150 border-b border-gray-200",
|
|
29864
|
-
"data-id": `dashboard_model_list_view_row_${index}`,
|
|
29864
|
+
"data-test-id": `dashboard_model_list_view_row_${index}`,
|
|
29865
29865
|
children: [
|
|
29866
|
-
/* @__PURE__ */ jsxRuntimeExports.jsxs("div", { className: "flex items-center gap-[8px]", "data-id": `dashboard_model_list_view_row_name_${index}`, children: [
|
|
29867
|
-
/* @__PURE__ */ jsxRuntimeExports.jsx("div", { className: "flex-shrink-0", "data-id": `dashboard_model_list_view_row_icon_${index}`, children: /* @__PURE__ */ jsxRuntimeExports.jsx(
|
|
29866
|
+
/* @__PURE__ */ jsxRuntimeExports.jsxs("div", { className: "flex items-center gap-[8px]", "data-test-id": `dashboard_model_list_view_row_name_${index}`, children: [
|
|
29867
|
+
/* @__PURE__ */ jsxRuntimeExports.jsx("div", { className: "flex-shrink-0", "data-test-id": `dashboard_model_list_view_row_icon_${index}`, children: /* @__PURE__ */ jsxRuntimeExports.jsx(
|
|
29868
29868
|
ModelIcon,
|
|
29869
29869
|
{
|
|
29870
29870
|
provider: model.provider
|
|
29871
29871
|
}
|
|
29872
29872
|
) }),
|
|
29873
|
-
/* @__PURE__ */ jsxRuntimeExports.jsxs("div", { className: "min-w-0 flex-1 w-full", "data-id": `dashboard_model_list_view_row_name_text_${index}`, children: [
|
|
29874
|
-
/* @__PURE__ */ jsxRuntimeExports.jsx("div", { className: "text-xs font-medium text-gray-700 truncate", "data-id": `dashboard_model_list_view_row_name_value_${index}`, children: model.name || model.modelName || "Unknown Model" }),
|
|
29875
|
-
model.provider && /* @__PURE__ */ jsxRuntimeExports.jsx("div", { className: "text-xs text-gray-500 truncate", "data-id": `dashboard_model_list_view_row_provider_${index}`, children: getProviderDisplayName(model.provider) })
|
|
29873
|
+
/* @__PURE__ */ jsxRuntimeExports.jsxs("div", { className: "min-w-0 flex-1 w-full", "data-test-id": `dashboard_model_list_view_row_name_text_${index}`, children: [
|
|
29874
|
+
/* @__PURE__ */ jsxRuntimeExports.jsx("div", { className: "text-xs font-medium text-gray-700 truncate", "data-test-id": `dashboard_model_list_view_row_name_value_${index}`, children: model.name || model.modelName || "Unknown Model" }),
|
|
29875
|
+
model.provider && /* @__PURE__ */ jsxRuntimeExports.jsx("div", { className: "text-xs text-gray-500 truncate", "data-test-id": `dashboard_model_list_view_row_provider_${index}`, children: getProviderDisplayName(model.provider) })
|
|
29876
29876
|
] })
|
|
29877
29877
|
] }),
|
|
29878
|
-
/* @__PURE__ */ jsxRuntimeExports.jsx("div", { className: "text-center font-medium text-xs text-gray-700", "data-id": `dashboard_model_list_view_row_runs_${index}`, children: formatValue2(model.runs || 0) }),
|
|
29879
|
-
/* @__PURE__ */ jsxRuntimeExports.jsx("div", { className: "text-center font-medium text-xs text-gray-700", "data-id": `dashboard_model_list_view_row_tokens_${index}`, children: formatValue2(model.tokens || model.totalTokens || 0) }),
|
|
29880
|
-
/* @__PURE__ */ jsxRuntimeExports.jsx("div", { className: "text-center font-medium text-xs text-gray-700", "data-id": `dashboard_model_list_view_row_response_time_${index}`, children: model.responseTime || (model.avgResponseTime ? `${model.avgResponseTime}ms` : "N/A") })
|
|
29878
|
+
/* @__PURE__ */ jsxRuntimeExports.jsx("div", { className: "text-center font-medium text-xs text-gray-700", "data-test-id": `dashboard_model_list_view_row_runs_${index}`, children: formatValue2(model.runs || 0) }),
|
|
29879
|
+
/* @__PURE__ */ jsxRuntimeExports.jsx("div", { className: "text-center font-medium text-xs text-gray-700", "data-test-id": `dashboard_model_list_view_row_tokens_${index}`, children: formatValue2(model.tokens || model.totalTokens || 0) }),
|
|
29880
|
+
/* @__PURE__ */ jsxRuntimeExports.jsx("div", { className: "text-center font-medium text-xs text-gray-700", "data-test-id": `dashboard_model_list_view_row_response_time_${index}`, children: model.responseTime || (model.avgResponseTime ? `${model.avgResponseTime}ms` : "N/A") })
|
|
29881
29881
|
]
|
|
29882
29882
|
},
|
|
29883
29883
|
model.id || index
|
|
29884
29884
|
)) }),
|
|
29885
|
-
visibleCount < data.length && /* @__PURE__ */ jsxRuntimeExports.jsx("div", { className: "flex justify-center", "data-id": "dashboard_model_list_view_load_more_container", children: /* @__PURE__ */ jsxRuntimeExports.jsx(
|
|
29885
|
+
visibleCount < data.length && /* @__PURE__ */ jsxRuntimeExports.jsx("div", { className: "flex justify-center", "data-test-id": "dashboard_model_list_view_load_more_container", children: /* @__PURE__ */ jsxRuntimeExports.jsx(
|
|
29886
29886
|
"button",
|
|
29887
29887
|
{
|
|
29888
29888
|
onClick: loadMore,
|
|
29889
29889
|
className: "px-[16px] py-[8px] text-xs font-medium text-gray-700 bg-white border border-gray-300 rounded-md hover:bg-gray-50 transition-colors duration-150",
|
|
29890
|
-
"data-id": "dashboard_model_list_view_load_more_btn",
|
|
29890
|
+
"data-test-id": "dashboard_model_list_view_load_more_btn",
|
|
29891
29891
|
children: "Load 10 more"
|
|
29892
29892
|
}
|
|
29893
29893
|
) })
|
|
@@ -30009,7 +30009,7 @@ const RunsSlider = ({
|
|
|
30009
30009
|
{
|
|
30010
30010
|
className: "fixed inset-0 bg-black bg-opacity-50 z-40 transition-opacity duration-300",
|
|
30011
30011
|
onClick: handleClose,
|
|
30012
|
-
"data-id": "dashboard_runs_slider_overlay"
|
|
30012
|
+
"data-test-id": "dashboard_runs_slider_overlay"
|
|
30013
30013
|
}
|
|
30014
30014
|
),
|
|
30015
30015
|
/* @__PURE__ */ jsxRuntimeExports.jsxs(
|
|
@@ -30020,42 +30020,42 @@ const RunsSlider = ({
|
|
|
30020
30020
|
isOpen ? "translate-x-0" : "translate-x-full",
|
|
30021
30021
|
className
|
|
30022
30022
|
),
|
|
30023
|
-
"data-id": "dashboard_runs_slider_panel",
|
|
30023
|
+
"data-test-id": "dashboard_runs_slider_panel",
|
|
30024
30024
|
children: [
|
|
30025
|
-
/* @__PURE__ */ jsxRuntimeExports.jsxs("div", { className: "flex items-center justify-between px-6 py-3 border-b border-[#d0d5dd]", "data-id": "dashboard_runs_slider_header", children: [
|
|
30026
|
-
/* @__PURE__ */ jsxRuntimeExports.jsx("h2", { className: "text-lg font-semibold text-[#101828]", "data-id": "dashboard_runs_slider_title", children: config2.title }),
|
|
30025
|
+
/* @__PURE__ */ jsxRuntimeExports.jsxs("div", { className: "flex items-center justify-between px-6 py-3 border-b border-[#d0d5dd]", "data-test-id": "dashboard_runs_slider_header", children: [
|
|
30026
|
+
/* @__PURE__ */ jsxRuntimeExports.jsx("h2", { className: "text-lg font-semibold text-[#101828]", "data-test-id": "dashboard_runs_slider_title", children: config2.title }),
|
|
30027
30027
|
/* @__PURE__ */ jsxRuntimeExports.jsx(
|
|
30028
30028
|
"button",
|
|
30029
30029
|
{
|
|
30030
30030
|
onClick: handleClose,
|
|
30031
30031
|
className: "p-2 hover:bg-gray-100 rounded-lg transition-colors",
|
|
30032
|
-
"data-id": "dashboard_runs_slider_close_btn",
|
|
30032
|
+
"data-test-id": "dashboard_runs_slider_close_btn",
|
|
30033
30033
|
children: /* @__PURE__ */ jsxRuntimeExports.jsx(X, { className: "h-5 w-5 text-[#101828]" })
|
|
30034
30034
|
}
|
|
30035
30035
|
)
|
|
30036
30036
|
] }),
|
|
30037
|
-
/* @__PURE__ */ jsxRuntimeExports.jsxs("div", { className: "flex flex-col h-[calc(100%-64px)] p-6 gap-6", "data-id": "dashboard_runs_slider_content", children: [
|
|
30038
|
-
/* @__PURE__ */ jsxRuntimeExports.jsxs("div", { className: "flex items-center justify-between", "data-id": "dashboard_runs_slider_subheader", children: [
|
|
30039
|
-
/* @__PURE__ */ jsxRuntimeExports.jsxs("div", { className: "text-sm font-medium text-[#344054]", "data-id": "dashboard_runs_slider_date_label", children: [
|
|
30037
|
+
/* @__PURE__ */ jsxRuntimeExports.jsxs("div", { className: "flex flex-col h-[calc(100%-64px)] p-6 gap-6", "data-test-id": "dashboard_runs_slider_content", children: [
|
|
30038
|
+
/* @__PURE__ */ jsxRuntimeExports.jsxs("div", { className: "flex items-center justify-between", "data-test-id": "dashboard_runs_slider_subheader", children: [
|
|
30039
|
+
/* @__PURE__ */ jsxRuntimeExports.jsxs("div", { className: "text-sm font-medium text-[#344054]", "data-test-id": "dashboard_runs_slider_date_label", children: [
|
|
30040
30040
|
config2.title,
|
|
30041
30041
|
" (",
|
|
30042
30042
|
formatDate(date2),
|
|
30043
30043
|
")"
|
|
30044
30044
|
] }),
|
|
30045
|
-
/* @__PURE__ */ jsxRuntimeExports.jsxs("div", { className: "w-[210px] relative filter-dropdown", "data-id": "dashboard_runs_slider_filter_dropdown", children: [
|
|
30045
|
+
/* @__PURE__ */ jsxRuntimeExports.jsxs("div", { className: "w-[210px] relative filter-dropdown", "data-test-id": "dashboard_runs_slider_filter_dropdown", children: [
|
|
30046
30046
|
/* @__PURE__ */ jsxRuntimeExports.jsxs(
|
|
30047
30047
|
"button",
|
|
30048
30048
|
{
|
|
30049
30049
|
onClick: () => setShowFilterDropdown(!showFilterDropdown),
|
|
30050
30050
|
className: "w-full bg-white border border-[#d0d5dd] rounded-lg px-3.5 py-2.5 flex items-center justify-between text-sm text-[#101828] hover:bg-gray-50 transition-colors",
|
|
30051
|
-
"data-id": "dashboard_runs_slider_filter_btn",
|
|
30051
|
+
"data-test-id": "dashboard_runs_slider_filter_btn",
|
|
30052
30052
|
children: [
|
|
30053
30053
|
/* @__PURE__ */ jsxRuntimeExports.jsx("span", { children: selectedFilterLabel }),
|
|
30054
30054
|
/* @__PURE__ */ jsxRuntimeExports.jsx(ChevronDown, { className: "h-4 w-4 text-[#101828]" })
|
|
30055
30055
|
]
|
|
30056
30056
|
}
|
|
30057
30057
|
),
|
|
30058
|
-
showFilterDropdown && /* @__PURE__ */ jsxRuntimeExports.jsx("div", { className: "absolute top-full left-0 right-0 mt-1 bg-white border border-[#d0d5dd] rounded-lg shadow-lg z-10 max-h-60 overflow-y-auto", "data-id": "dashboard_runs_slider_filter_menu", children: filterOptions.map((option) => /* @__PURE__ */ jsxRuntimeExports.jsx(
|
|
30058
|
+
showFilterDropdown && /* @__PURE__ */ jsxRuntimeExports.jsx("div", { className: "absolute top-full left-0 right-0 mt-1 bg-white border border-[#d0d5dd] rounded-lg shadow-lg z-10 max-h-60 overflow-y-auto", "data-test-id": "dashboard_runs_slider_filter_menu", children: filterOptions.map((option) => /* @__PURE__ */ jsxRuntimeExports.jsx(
|
|
30059
30059
|
"button",
|
|
30060
30060
|
{
|
|
30061
30061
|
onClick: () => handleFilterSelect(option.value),
|
|
@@ -30063,26 +30063,26 @@ const RunsSlider = ({
|
|
|
30063
30063
|
"w-full px-3.5 py-2.5 text-left text-sm hover:bg-gray-50 transition-colors",
|
|
30064
30064
|
selectedFilter === option.value ? "bg-blue-50 text-blue-700" : "text-[#101828]"
|
|
30065
30065
|
),
|
|
30066
|
-
"data-id": `dashboard_runs_slider_filter_option_${option.value}`,
|
|
30066
|
+
"data-test-id": `dashboard_runs_slider_filter_option_${option.value}`,
|
|
30067
30067
|
children: option.label
|
|
30068
30068
|
},
|
|
30069
30069
|
option.value
|
|
30070
30070
|
)) })
|
|
30071
30071
|
] })
|
|
30072
30072
|
] }),
|
|
30073
|
-
/* @__PURE__ */ jsxRuntimeExports.jsxs("div", { className: "flex-1 overflow-hidden", "data-id": "dashboard_runs_slider_table_container", children: [
|
|
30074
|
-
/* @__PURE__ */ jsxRuntimeExports.jsx("div", { className: "bg-[#f9fafb] border-b border-[#eaecf0] px-2 py-2", "data-id": "dashboard_runs_slider_table_header", children: /* @__PURE__ */ jsxRuntimeExports.jsxs("div", { className: "grid grid-cols-4 gap-3 items-center", "data-id": "dashboard_runs_slider_table_header_row", children: [
|
|
30075
|
-
/* @__PURE__ */ jsxRuntimeExports.jsx("div", { className: "col-span-2 px-0 py-2", "data-id": "dashboard_runs_slider_table_header_name", children: /* @__PURE__ */ jsxRuntimeExports.jsx("div", { className: "text-xs font-medium text-[#475467]", children: "Name" }) }),
|
|
30076
|
-
/* @__PURE__ */ jsxRuntimeExports.jsx("div", { className: "flex justify-center px-0 py-2", "data-id": "dashboard_runs_slider_table_header_runs", children: /* @__PURE__ */ jsxRuntimeExports.jsx("div", { className: "text-xs font-medium text-[#475467]", children: "Runs" }) }),
|
|
30077
|
-
/* @__PURE__ */ jsxRuntimeExports.jsx("div", { className: "flex justify-center px-0 py-2", "data-id": "dashboard_runs_slider_table_header_response_time", children: /* @__PURE__ */ jsxRuntimeExports.jsx("div", { className: "text-xs font-medium text-[#475467]", children: "Response Time" }) })
|
|
30073
|
+
/* @__PURE__ */ jsxRuntimeExports.jsxs("div", { className: "flex-1 overflow-hidden", "data-test-id": "dashboard_runs_slider_table_container", children: [
|
|
30074
|
+
/* @__PURE__ */ jsxRuntimeExports.jsx("div", { className: "bg-[#f9fafb] border-b border-[#eaecf0] px-2 py-2", "data-test-id": "dashboard_runs_slider_table_header", children: /* @__PURE__ */ jsxRuntimeExports.jsxs("div", { className: "grid grid-cols-4 gap-3 items-center", "data-test-id": "dashboard_runs_slider_table_header_row", children: [
|
|
30075
|
+
/* @__PURE__ */ jsxRuntimeExports.jsx("div", { className: "col-span-2 px-0 py-2", "data-test-id": "dashboard_runs_slider_table_header_name", children: /* @__PURE__ */ jsxRuntimeExports.jsx("div", { className: "text-xs font-medium text-[#475467]", children: "Name" }) }),
|
|
30076
|
+
/* @__PURE__ */ jsxRuntimeExports.jsx("div", { className: "flex justify-center px-0 py-2", "data-test-id": "dashboard_runs_slider_table_header_runs", children: /* @__PURE__ */ jsxRuntimeExports.jsx("div", { className: "text-xs font-medium text-[#475467]", children: "Runs" }) }),
|
|
30077
|
+
/* @__PURE__ */ jsxRuntimeExports.jsx("div", { className: "flex justify-center px-0 py-2", "data-test-id": "dashboard_runs_slider_table_header_response_time", children: /* @__PURE__ */ jsxRuntimeExports.jsx("div", { className: "text-xs font-medium text-[#475467]", children: "Response Time" }) })
|
|
30078
30078
|
] }) }),
|
|
30079
|
-
/* @__PURE__ */ jsxRuntimeExports.jsx("div", { className: "overflow-y-auto max-h-[calc(100%-40px)]", "data-id": "dashboard_runs_slider_table_body", children: visibleData.length === 0 ? /* @__PURE__ */ jsxRuntimeExports.jsxs("div", { className: "flex flex-col items-center justify-center h-64 text-center", "data-id": "dashboard_runs_slider_empty_state", children: [
|
|
30080
|
-
/* @__PURE__ */ jsxRuntimeExports.jsxs("h3", { className: "text-md font-medium text-gray-900 mb-[8px]", "data-id": "dashboard_runs_slider_empty_state_title", children: [
|
|
30079
|
+
/* @__PURE__ */ jsxRuntimeExports.jsx("div", { className: "overflow-y-auto max-h-[calc(100%-40px)]", "data-test-id": "dashboard_runs_slider_table_body", children: visibleData.length === 0 ? /* @__PURE__ */ jsxRuntimeExports.jsxs("div", { className: "flex flex-col items-center justify-center h-64 text-center", "data-test-id": "dashboard_runs_slider_empty_state", children: [
|
|
30080
|
+
/* @__PURE__ */ jsxRuntimeExports.jsxs("h3", { className: "text-md font-medium text-gray-900 mb-[8px]", "data-test-id": "dashboard_runs_slider_empty_state_title", children: [
|
|
30081
30081
|
"No ",
|
|
30082
30082
|
config2.title.toLowerCase(),
|
|
30083
30083
|
" for this date"
|
|
30084
30084
|
] }),
|
|
30085
|
-
/* @__PURE__ */ jsxRuntimeExports.jsxs("p", { className: "text-xs text-gray-500", "data-id": "dashboard_runs_slider_empty_state_message", children: [
|
|
30085
|
+
/* @__PURE__ */ jsxRuntimeExports.jsxs("p", { className: "text-xs text-gray-500", "data-test-id": "dashboard_runs_slider_empty_state_message", children: [
|
|
30086
30086
|
"There were no ",
|
|
30087
30087
|
config2.title.toLowerCase(),
|
|
30088
30088
|
" recorded on ",
|
|
@@ -30094,10 +30094,10 @@ const RunsSlider = ({
|
|
|
30094
30094
|
"div",
|
|
30095
30095
|
{
|
|
30096
30096
|
className: "grid grid-cols-4 gap-3 items-center px-2 py-3 border-b border-[#eaecf0] hover:bg-gray-50 transition-colors",
|
|
30097
|
-
"data-id": `dashboard_runs_slider_table_row_${index}`,
|
|
30097
|
+
"data-test-id": `dashboard_runs_slider_table_row_${index}`,
|
|
30098
30098
|
children: [
|
|
30099
|
-
/* @__PURE__ */ jsxRuntimeExports.jsxs("div", { className: "col-span-2 flex items-center gap-2", "data-id": `dashboard_runs_slider_table_row_name_${index}`, children: [
|
|
30100
|
-
/* @__PURE__ */ jsxRuntimeExports.jsx("div", { className: "flex-shrink-0", "data-id": `dashboard_runs_slider_table_row_avatar_${index}`, children: /* @__PURE__ */ jsxRuntimeExports.jsx(
|
|
30099
|
+
/* @__PURE__ */ jsxRuntimeExports.jsxs("div", { className: "col-span-2 flex items-center gap-2", "data-test-id": `dashboard_runs_slider_table_row_name_${index}`, children: [
|
|
30100
|
+
/* @__PURE__ */ jsxRuntimeExports.jsx("div", { className: "flex-shrink-0", "data-test-id": `dashboard_runs_slider_table_row_avatar_${index}`, children: /* @__PURE__ */ jsxRuntimeExports.jsx(
|
|
30101
30101
|
IconPreview,
|
|
30102
30102
|
{
|
|
30103
30103
|
icon: item.icon,
|
|
@@ -30109,23 +30109,23 @@ const RunsSlider = ({
|
|
|
30109
30109
|
modelName: item.modelName
|
|
30110
30110
|
}
|
|
30111
30111
|
) }),
|
|
30112
|
-
/* @__PURE__ */ jsxRuntimeExports.jsxs("div", { className: "min-w-0 flex-1", "data-id": `dashboard_runs_slider_table_row_name_text_${index}`, children: [
|
|
30112
|
+
/* @__PURE__ */ jsxRuntimeExports.jsxs("div", { className: "min-w-0 flex-1", "data-test-id": `dashboard_runs_slider_table_row_name_text_${index}`, children: [
|
|
30113
30113
|
/* @__PURE__ */ jsxRuntimeExports.jsx("div", { className: "text-sm font-medium text-[#101828] truncate", children: item.name }),
|
|
30114
|
-
metricType === "modelRuns" && item.provider && /* @__PURE__ */ jsxRuntimeExports.jsx("div", { className: "text-xs text-[#475467] truncate", "data-id": `dashboard_runs_slider_table_row_provider_${index}`, children: item.provider })
|
|
30114
|
+
metricType === "modelRuns" && item.provider && /* @__PURE__ */ jsxRuntimeExports.jsx("div", { className: "text-xs text-[#475467] truncate", "data-test-id": `dashboard_runs_slider_table_row_provider_${index}`, children: item.provider })
|
|
30115
30115
|
] })
|
|
30116
30116
|
] }),
|
|
30117
|
-
/* @__PURE__ */ jsxRuntimeExports.jsx("div", { className: "flex justify-center", "data-id": `dashboard_runs_slider_table_row_runs_${index}`, children: /* @__PURE__ */ jsxRuntimeExports.jsx("div", { className: "text-xs font-medium text-[#475467]", children: formatValue(item.runs) }) }),
|
|
30118
|
-
/* @__PURE__ */ jsxRuntimeExports.jsx("div", { className: "flex justify-center", "data-id": `dashboard_runs_slider_table_row_response_time_${index}`, children: /* @__PURE__ */ jsxRuntimeExports.jsx("div", { className: "text-xs font-medium text-[#475467]", children: item.responseTime }) })
|
|
30117
|
+
/* @__PURE__ */ jsxRuntimeExports.jsx("div", { className: "flex justify-center", "data-test-id": `dashboard_runs_slider_table_row_runs_${index}`, children: /* @__PURE__ */ jsxRuntimeExports.jsx("div", { className: "text-xs font-medium text-[#475467]", children: formatValue(item.runs) }) }),
|
|
30118
|
+
/* @__PURE__ */ jsxRuntimeExports.jsx("div", { className: "flex justify-center", "data-test-id": `dashboard_runs_slider_table_row_response_time_${index}`, children: /* @__PURE__ */ jsxRuntimeExports.jsx("div", { className: "text-xs font-medium text-[#475467]", children: item.responseTime }) })
|
|
30119
30119
|
]
|
|
30120
30120
|
},
|
|
30121
30121
|
item.id || index
|
|
30122
30122
|
)),
|
|
30123
|
-
visibleCount < filteredData.length && /* @__PURE__ */ jsxRuntimeExports.jsx("div", { className: "flex justify-center", "data-id": "dashboard_runs_slider_load_more_container", children: /* @__PURE__ */ jsxRuntimeExports.jsx(
|
|
30123
|
+
visibleCount < filteredData.length && /* @__PURE__ */ jsxRuntimeExports.jsx("div", { className: "flex justify-center", "data-test-id": "dashboard_runs_slider_load_more_container", children: /* @__PURE__ */ jsxRuntimeExports.jsx(
|
|
30124
30124
|
"button",
|
|
30125
30125
|
{
|
|
30126
30126
|
onClick: loadMore,
|
|
30127
30127
|
className: "bg-white border border-[#d0d5dd] rounded px-3 py-1 text-xs font-medium text-[#344054] hover:bg-gray-50 transition-colors",
|
|
30128
|
-
"data-id": "dashboard_runs_slider_load_more_btn",
|
|
30128
|
+
"data-test-id": "dashboard_runs_slider_load_more_btn",
|
|
30129
30129
|
children: "Load 10 more"
|
|
30130
30130
|
}
|
|
30131
30131
|
) })
|
|
@@ -31743,7 +31743,7 @@ const ViewRenderer = ({
|
|
|
31743
31743
|
}
|
|
31744
31744
|
};
|
|
31745
31745
|
return /* @__PURE__ */ jsxRuntimeExports.jsxs(jsxRuntimeExports.Fragment, { children: [
|
|
31746
|
-
/* @__PURE__ */ jsxRuntimeExports.jsx("div", { className: cn("w-full", className), "data-id": "dashboard_view_renderer_root", children: renderView() }),
|
|
31746
|
+
/* @__PURE__ */ jsxRuntimeExports.jsx("div", { className: cn("w-full", className), "data-test-id": "dashboard_view_renderer_root", children: renderView() }),
|
|
31747
31747
|
/* @__PURE__ */ jsxRuntimeExports.jsx(
|
|
31748
31748
|
RunsSlider,
|
|
31749
31749
|
{
|
|
@@ -32156,7 +32156,7 @@ const SectionControls = ({
|
|
|
32156
32156
|
}
|
|
32157
32157
|
return { maxItems: 40, maxLabelLength: 25 };
|
|
32158
32158
|
};
|
|
32159
|
-
return /* @__PURE__ */ jsxRuntimeExports.jsxs("div", { className: cn("flex items-center gap-3", className), "data-id": "dashboard_section_controls", children: [
|
|
32159
|
+
return /* @__PURE__ */ jsxRuntimeExports.jsxs("div", { className: cn("flex items-center gap-3", className), "data-test-id": "dashboard_section_controls", children: [
|
|
32160
32160
|
dropdown && /* @__PURE__ */ jsxRuntimeExports.jsx(jsxRuntimeExports.Fragment, { children: dropdown.multiSelect ? /* @__PURE__ */ jsxRuntimeExports.jsx(
|
|
32161
32161
|
MultiSelect,
|
|
32162
32162
|
{
|
|
@@ -32184,7 +32184,7 @@ const SectionControls = ({
|
|
|
32184
32184
|
className: "w-48"
|
|
32185
32185
|
}
|
|
32186
32186
|
) }),
|
|
32187
|
-
buttons && buttons.length > 0 && /* @__PURE__ */ jsxRuntimeExports.jsx("div", { className: "flex items-center border border-gray-200 rounded-lg overflow-hidden", "data-id": "dashboard_section_controls_button_group", children: buttons.map((button, index) => /* @__PURE__ */ jsxRuntimeExports.jsx(
|
|
32187
|
+
buttons && buttons.length > 0 && /* @__PURE__ */ jsxRuntimeExports.jsx("div", { className: "flex items-center border border-gray-200 rounded-lg overflow-hidden", "data-test-id": "dashboard_section_controls_button_group", children: buttons.map((button, index) => /* @__PURE__ */ jsxRuntimeExports.jsx(
|
|
32188
32188
|
"button",
|
|
32189
32189
|
{
|
|
32190
32190
|
onClick: () => {
|
|
@@ -32197,12 +32197,12 @@ const SectionControls = ({
|
|
|
32197
32197
|
button.active ? "bg-white text-gray-900 shadow-[0 1px 3px 0 rgba(16, 24, 40, 0.08), 0 1px 2px 0 rgba(16, 24, 40, 0.08)]" : "text-gray-500 bg-white",
|
|
32198
32198
|
index > 0 && "border-l border-gray-200"
|
|
32199
32199
|
),
|
|
32200
|
-
"data-id": `dashboard_section_controls_btn_${button.value}`,
|
|
32200
|
+
"data-test-id": `dashboard_section_controls_btn_${button.value}`,
|
|
32201
32201
|
children: button.icon && /* @__PURE__ */ jsxRuntimeExports.jsx("span", { className: "mr-[8px]", children: button.icon })
|
|
32202
32202
|
},
|
|
32203
32203
|
button.value
|
|
32204
32204
|
)) }),
|
|
32205
|
-
toggle && /* @__PURE__ */ jsxRuntimeExports.jsxs("div", { className: "flex items-center gap-[4px] border border-gray-200 bg-gray-50 overflow-hidden p-[2px] rounded-[6px]", "data-id": "dashboard_section_controls_view_toggle", children: [
|
|
32205
|
+
toggle && /* @__PURE__ */ jsxRuntimeExports.jsxs("div", { className: "flex items-center gap-[4px] border border-gray-200 bg-gray-50 overflow-hidden p-[2px] rounded-[6px]", "data-test-id": "dashboard_section_controls_view_toggle", children: [
|
|
32206
32206
|
/* @__PURE__ */ jsxRuntimeExports.jsx(
|
|
32207
32207
|
"button",
|
|
32208
32208
|
{
|
|
@@ -32215,7 +32215,7 @@ const SectionControls = ({
|
|
|
32215
32215
|
"hover:bg-white ",
|
|
32216
32216
|
toggle.chartView ? "bg-white text-gray-900 shadow-md" : "text-gray-500 bg-white"
|
|
32217
32217
|
),
|
|
32218
|
-
"data-id": "dashboard_section_controls_view_toggle_btn_chart",
|
|
32218
|
+
"data-test-id": "dashboard_section_controls_view_toggle_btn_chart",
|
|
32219
32219
|
children: /* @__PURE__ */ jsxRuntimeExports.jsx(BarChart3, { className: "w-[16px] h-[16px]" })
|
|
32220
32220
|
}
|
|
32221
32221
|
),
|
|
@@ -32231,7 +32231,7 @@ const SectionControls = ({
|
|
|
32231
32231
|
"hover:bg-white ",
|
|
32232
32232
|
toggle.tableView ? "bg-white text-gray-900 shadow-md" : "text-gray-500 bg-white"
|
|
32233
32233
|
),
|
|
32234
|
-
"data-id": "dashboard_section_controls_view_toggle_btn_table",
|
|
32234
|
+
"data-test-id": "dashboard_section_controls_view_toggle_btn_table",
|
|
32235
32235
|
children: /* @__PURE__ */ jsxRuntimeExports.jsx(Table$1, { className: "w-[16px] h-[16px]" })
|
|
32236
32236
|
}
|
|
32237
32237
|
)
|
|
@@ -32845,18 +32845,18 @@ const DashboardSection = ({
|
|
|
32845
32845
|
gridColumn: (layout == null ? void 0 : layout.span) ? `span ${layout.span}` : void 0,
|
|
32846
32846
|
order: layout == null ? void 0 : layout.order
|
|
32847
32847
|
},
|
|
32848
|
-
"data-id": `dashboard_section_${id}`,
|
|
32848
|
+
"data-test-id": `dashboard_section_${id}`,
|
|
32849
32849
|
children: [
|
|
32850
|
-
title && /* @__PURE__ */ jsxRuntimeExports.jsxs("div", { className: "w-full", "data-id": `dashboard_section_header_${id}`, children: [
|
|
32851
|
-
/* @__PURE__ */ jsxRuntimeExports.jsx("h1", { className: "text-md font-medium text-gray-700", "data-id": `dashboard_section_title_${id}`, children: title }),
|
|
32852
|
-
description && /* @__PURE__ */ jsxRuntimeExports.jsx("p", { className: "text-xs text-gray-500", "data-id": `dashboard_section_description_${id}`, children: description })
|
|
32850
|
+
title && /* @__PURE__ */ jsxRuntimeExports.jsxs("div", { className: "w-full", "data-test-id": `dashboard_section_header_${id}`, children: [
|
|
32851
|
+
/* @__PURE__ */ jsxRuntimeExports.jsx("h1", { className: "text-md font-medium text-gray-700", "data-test-id": `dashboard_section_title_${id}`, children: title }),
|
|
32852
|
+
description && /* @__PURE__ */ jsxRuntimeExports.jsx("p", { className: "text-xs text-gray-500", "data-test-id": `dashboard_section_description_${id}`, children: description })
|
|
32853
32853
|
] }),
|
|
32854
|
-
/* @__PURE__ */ jsxRuntimeExports.jsx("div", { className: "flex flex-col sm:flex-row gap-[16px]", "data-id": `dashboard_section_metrics_${id}`, children: isLoading ? /* @__PURE__ */ jsxRuntimeExports.jsxs(jsxRuntimeExports.Fragment, { children: [
|
|
32855
|
-
/* @__PURE__ */ jsxRuntimeExports.jsx("div", { className: "flex-1", "data-id": `dashboard_section_metric_skeleton_${id}_0`, children: /* @__PURE__ */ jsxRuntimeExports.jsx(MetricCardSkeleton, {}) }),
|
|
32856
|
-
/* @__PURE__ */ jsxRuntimeExports.jsx("div", { className: "flex-1", "data-id": `dashboard_section_metric_skeleton_${id}_1`, children: /* @__PURE__ */ jsxRuntimeExports.jsx(MetricCardSkeleton, {}) }),
|
|
32857
|
-
/* @__PURE__ */ jsxRuntimeExports.jsx("div", { className: "flex-1", "data-id": `dashboard_section_metric_skeleton_${id}_2`, children: /* @__PURE__ */ jsxRuntimeExports.jsx(MetricCardSkeleton, {}) }),
|
|
32858
|
-
/* @__PURE__ */ jsxRuntimeExports.jsx("div", { className: "flex-1", "data-id": `dashboard_section_metric_skeleton_${id}_3`, children: /* @__PURE__ */ jsxRuntimeExports.jsx(MetricCardSkeleton, {}) })
|
|
32859
|
-
] }) : getUpdatedMetrics().map((metric, index) => /* @__PURE__ */ jsxRuntimeExports.jsx("div", { className: "flex-1", "data-id": `dashboard_section_metric_${id}_${index}`, children: /* @__PURE__ */ jsxRuntimeExports.jsx(
|
|
32854
|
+
/* @__PURE__ */ jsxRuntimeExports.jsx("div", { className: "flex flex-col sm:flex-row gap-[16px]", "data-test-id": `dashboard_section_metrics_${id}`, children: isLoading ? /* @__PURE__ */ jsxRuntimeExports.jsxs(jsxRuntimeExports.Fragment, { children: [
|
|
32855
|
+
/* @__PURE__ */ jsxRuntimeExports.jsx("div", { className: "flex-1", "data-test-id": `dashboard_section_metric_skeleton_${id}_0`, children: /* @__PURE__ */ jsxRuntimeExports.jsx(MetricCardSkeleton, {}) }),
|
|
32856
|
+
/* @__PURE__ */ jsxRuntimeExports.jsx("div", { className: "flex-1", "data-test-id": `dashboard_section_metric_skeleton_${id}_1`, children: /* @__PURE__ */ jsxRuntimeExports.jsx(MetricCardSkeleton, {}) }),
|
|
32857
|
+
/* @__PURE__ */ jsxRuntimeExports.jsx("div", { className: "flex-1", "data-test-id": `dashboard_section_metric_skeleton_${id}_2`, children: /* @__PURE__ */ jsxRuntimeExports.jsx(MetricCardSkeleton, {}) }),
|
|
32858
|
+
/* @__PURE__ */ jsxRuntimeExports.jsx("div", { className: "flex-1", "data-test-id": `dashboard_section_metric_skeleton_${id}_3`, children: /* @__PURE__ */ jsxRuntimeExports.jsx(MetricCardSkeleton, {}) })
|
|
32859
|
+
] }) : getUpdatedMetrics().map((metric, index) => /* @__PURE__ */ jsxRuntimeExports.jsx("div", { className: "flex-1", "data-test-id": `dashboard_section_metric_${id}_${index}`, children: /* @__PURE__ */ jsxRuntimeExports.jsx(
|
|
32860
32860
|
MetricCard,
|
|
32861
32861
|
{
|
|
32862
32862
|
data: metric,
|
|
@@ -32864,8 +32864,8 @@ const DashboardSection = ({
|
|
|
32864
32864
|
isFirst: index === 0
|
|
32865
32865
|
}
|
|
32866
32866
|
) }, `${id}-metric-${index}`)) }),
|
|
32867
|
-
/* @__PURE__ */ jsxRuntimeExports.jsxs("div", { className: "flex items-center justify-between", "data-id": `dashboard_section_subtitle_${id}`, children: [
|
|
32868
|
-
/* @__PURE__ */ jsxRuntimeExports.jsx("div", { "data-id": `dashboard_section_current_metric_${id}`, children: getCurrentMetric() && /* @__PURE__ */ jsxRuntimeExports.jsx("h3", { className: "text-md font-medium text-gray-700", "data-id": `dashboard_section_current_metric_title_${id}`, children: (_a = getCurrentMetric()) == null ? void 0 : _a.title }) }),
|
|
32867
|
+
/* @__PURE__ */ jsxRuntimeExports.jsxs("div", { className: "flex items-center justify-between", "data-test-id": `dashboard_section_subtitle_${id}`, children: [
|
|
32868
|
+
/* @__PURE__ */ jsxRuntimeExports.jsx("div", { "data-test-id": `dashboard_section_current_metric_${id}`, children: getCurrentMetric() && /* @__PURE__ */ jsxRuntimeExports.jsx("h3", { className: "text-md font-medium text-gray-700", "data-test-id": `dashboard_section_current_metric_title_${id}`, children: (_a = getCurrentMetric()) == null ? void 0 : _a.title }) }),
|
|
32869
32869
|
enhancedControls && /* @__PURE__ */ jsxRuntimeExports.jsx(SectionControls, { config: enhancedControls })
|
|
32870
32870
|
] }),
|
|
32871
32871
|
/* @__PURE__ */ jsxRuntimeExports.jsx(
|
|
@@ -33034,12 +33034,6 @@ function isValid(dirtyDate) {
|
|
|
33034
33034
|
var date2 = toDate(dirtyDate);
|
|
33035
33035
|
return !isNaN(Number(date2));
|
|
33036
33036
|
}
|
|
33037
|
-
function endOfDay(dirtyDate) {
|
|
33038
|
-
requiredArgs(1, arguments);
|
|
33039
|
-
var date2 = toDate(dirtyDate);
|
|
33040
|
-
date2.setHours(23, 59, 59, 999);
|
|
33041
|
-
return date2;
|
|
33042
|
-
}
|
|
33043
33037
|
function startOfMonth(dirtyDate) {
|
|
33044
33038
|
requiredArgs(1, arguments);
|
|
33045
33039
|
var date2 = toDate(dirtyDate);
|
|
@@ -34529,19 +34523,19 @@ function TailwindDateRangePicker({ className, defaultValue, value, presetLabel:
|
|
|
34529
34523
|
});
|
|
34530
34524
|
const presets = [
|
|
34531
34525
|
{
|
|
34532
|
-
label: "
|
|
34533
|
-
value: "
|
|
34526
|
+
label: "Last 24 hours",
|
|
34527
|
+
value: "24h",
|
|
34534
34528
|
dateRange: {
|
|
34535
|
-
from:
|
|
34529
|
+
from: subDays(/* @__PURE__ */ new Date(), 1),
|
|
34536
34530
|
to: /* @__PURE__ */ new Date()
|
|
34537
34531
|
}
|
|
34538
34532
|
},
|
|
34539
34533
|
{
|
|
34540
|
-
label: "
|
|
34541
|
-
value: "
|
|
34534
|
+
label: "Last 48 hours",
|
|
34535
|
+
value: "48h",
|
|
34542
34536
|
dateRange: {
|
|
34543
|
-
from:
|
|
34544
|
-
to:
|
|
34537
|
+
from: subDays(/* @__PURE__ */ new Date(), 2),
|
|
34538
|
+
to: /* @__PURE__ */ new Date()
|
|
34545
34539
|
}
|
|
34546
34540
|
},
|
|
34547
34541
|
{
|
|
@@ -35218,6 +35212,7 @@ const Dashboard = ({
|
|
|
35218
35212
|
} else if (typeof value === "string") {
|
|
35219
35213
|
const daysMap = {
|
|
35220
35214
|
"24h": 1,
|
|
35215
|
+
"48h": 2,
|
|
35221
35216
|
"7d": 7,
|
|
35222
35217
|
"30d": 30,
|
|
35223
35218
|
"90d": 90
|
|
@@ -35251,13 +35246,13 @@ const Dashboard = ({
|
|
|
35251
35246
|
onExport == null ? void 0 : onExport();
|
|
35252
35247
|
};
|
|
35253
35248
|
const isAnyChartLoading = Object.values(sectionChartLoading).some((loading) => loading);
|
|
35254
|
-
return /* @__PURE__ */ jsxRuntimeExports.jsxs("div", { className: cn("w-full h-full flex flex-col overflow-hidden", className), "data-id": "dashboard_root", children: [
|
|
35255
|
-
/* @__PURE__ */ jsxRuntimeExports.jsxs("div", { className: "flex flex-col gap-2 w-full p-[24px] pb-[12px]", "data-id": "dashboard_header", children: [
|
|
35256
|
-
/* @__PURE__ */ jsxRuntimeExports.jsx("h1", { className: "text-lg font-bold text-gray-900 w-full", "data-id": "dashboard_title", children: title }),
|
|
35257
|
-
/* @__PURE__ */ jsxRuntimeExports.jsxs("div", { className: "flex items-center gap-2 w-full", "data-id": "dashboard_header_content", children: [
|
|
35258
|
-
subtitle && /* @__PURE__ */ jsxRuntimeExports.jsx("p", { className: "text-gray-500 text-xs w-full", "data-id": "dashboard_subtitle", children: subtitle }),
|
|
35259
|
-
/* @__PURE__ */ jsxRuntimeExports.jsxs("div", { className: "flex items-center gap-2 justify-end flex-shrink-0", "data-id": "dashboard_global_controls", children: [
|
|
35260
|
-
(isInitialLoading || isAnyChartLoading) && /* @__PURE__ */ jsxRuntimeExports.jsxs("div", { className: "flex items-center gap-2 text-sm medium text-gray-500", "data-id": "dashboard_loading_indicator", children: [
|
|
35249
|
+
return /* @__PURE__ */ jsxRuntimeExports.jsxs("div", { className: cn("w-full h-full flex flex-col overflow-hidden", className), "data-test-id": "dashboard_root", children: [
|
|
35250
|
+
/* @__PURE__ */ jsxRuntimeExports.jsxs("div", { className: "flex flex-col gap-2 w-full p-[24px] pb-[12px]", "data-test-id": "dashboard_header", children: [
|
|
35251
|
+
/* @__PURE__ */ jsxRuntimeExports.jsx("h1", { className: "text-lg font-bold text-gray-900 w-full", "data-test-id": "dashboard_title", children: title }),
|
|
35252
|
+
/* @__PURE__ */ jsxRuntimeExports.jsxs("div", { className: "flex items-center gap-2 w-full", "data-test-id": "dashboard_header_content", children: [
|
|
35253
|
+
subtitle && /* @__PURE__ */ jsxRuntimeExports.jsx("p", { className: "text-gray-500 text-xs w-full", "data-test-id": "dashboard_subtitle", children: subtitle }),
|
|
35254
|
+
/* @__PURE__ */ jsxRuntimeExports.jsxs("div", { className: "flex items-center gap-2 justify-end flex-shrink-0", "data-test-id": "dashboard_global_controls", children: [
|
|
35255
|
+
(isInitialLoading || isAnyChartLoading) && /* @__PURE__ */ jsxRuntimeExports.jsxs("div", { className: "flex items-center gap-2 text-sm medium text-gray-500", "data-test-id": "dashboard_loading_indicator", children: [
|
|
35261
35256
|
/* @__PURE__ */ jsxRuntimeExports.jsx(RefreshCw, { className: "h-[16px] w-[16px] animate-spin" }),
|
|
35262
35257
|
"Loading..."
|
|
35263
35258
|
] }),
|
|
@@ -35336,7 +35331,7 @@ const Dashboard = ({
|
|
|
35336
35331
|
gridTemplateColumns: layout.responsive ? void 0 : `repeat(${layout.columns}, minmax(0, 1fr))`,
|
|
35337
35332
|
gap: layout.gap ? `${layout.gap}px` : void 0
|
|
35338
35333
|
},
|
|
35339
|
-
"data-id": "dashboard_sections_grid",
|
|
35334
|
+
"data-test-id": "dashboard_sections_grid",
|
|
35340
35335
|
children: dynamicSections.map((section) => {
|
|
35341
35336
|
var _a2, _b, _c, _d;
|
|
35342
35337
|
return /* @__PURE__ */ jsxRuntimeExports.jsx(
|
|
@@ -35368,7 +35363,8 @@ class TracingApiService {
|
|
|
35368
35363
|
console.log("🔧 TracingApiService initialized:", {
|
|
35369
35364
|
tracingUrl: config2.tracingUrl,
|
|
35370
35365
|
projectId: config2.projectId,
|
|
35371
|
-
hasAuth: !!config2.headers.authorization
|
|
35366
|
+
hasAuth: !!config2.headers.authorization,
|
|
35367
|
+
hasDynamicAuth: !!config2.getAuthHeaders
|
|
35372
35368
|
});
|
|
35373
35369
|
}
|
|
35374
35370
|
/**
|
|
@@ -35378,15 +35374,36 @@ class TracingApiService {
|
|
|
35378
35374
|
const encodedInput = encodeURIComponent(JSON.stringify(input));
|
|
35379
35375
|
return `${this.config.tracingUrl}/tracing/api/trpc/${endpoint}?input=${encodedInput}`;
|
|
35380
35376
|
}
|
|
35377
|
+
/**
|
|
35378
|
+
* Get current headers, refreshing auth token if callback is provided
|
|
35379
|
+
*/
|
|
35380
|
+
async getHeaders() {
|
|
35381
|
+
if (this.config.getAuthHeaders) {
|
|
35382
|
+
try {
|
|
35383
|
+
const authHeaders = await this.config.getAuthHeaders();
|
|
35384
|
+
return {
|
|
35385
|
+
...this.config.headers,
|
|
35386
|
+
authorization: authHeaders.authorization,
|
|
35387
|
+
accountid: authHeaders.accountid,
|
|
35388
|
+
userId: authHeaders.userId || this.config.headers.userId || ""
|
|
35389
|
+
};
|
|
35390
|
+
} catch (error) {
|
|
35391
|
+
console.warn("⚠️ Failed to get fresh auth headers, using static headers:", error);
|
|
35392
|
+
return this.config.headers;
|
|
35393
|
+
}
|
|
35394
|
+
}
|
|
35395
|
+
return this.config.headers;
|
|
35396
|
+
}
|
|
35381
35397
|
/**
|
|
35382
35398
|
* Helper to make GET request with proper headers
|
|
35383
35399
|
*/
|
|
35384
35400
|
async makeRequest(url) {
|
|
35385
35401
|
var _a, _b, _c;
|
|
35386
35402
|
console.log("📤 API Request:", url);
|
|
35403
|
+
const headers = await this.getHeaders();
|
|
35387
35404
|
const response = await fetch(url, {
|
|
35388
35405
|
method: "GET",
|
|
35389
|
-
headers
|
|
35406
|
+
headers
|
|
35390
35407
|
});
|
|
35391
35408
|
console.log("📥 API Response status:", response.status);
|
|
35392
35409
|
if (!response.ok) {
|
|
@@ -35773,9 +35790,10 @@ class TracingApiService {
|
|
|
35773
35790
|
try {
|
|
35774
35791
|
const url = `${this.config.tracingUrl}/aaa/api/v1/apps/${this.config.projectId}/environments?rnd=${Math.random().toString(36).substring(2, 8)}`;
|
|
35775
35792
|
console.log("🌍 Fetching environments for project:", this.config.projectId);
|
|
35793
|
+
const headers = await this.getHeaders();
|
|
35776
35794
|
const response = await fetch(url, {
|
|
35777
35795
|
method: "GET",
|
|
35778
|
-
headers
|
|
35796
|
+
headers
|
|
35779
35797
|
});
|
|
35780
35798
|
if (!response.ok) {
|
|
35781
35799
|
const errorText = await response.text();
|
|
@@ -104863,11 +104881,11 @@ function TracingListHeader(props) {
|
|
|
104863
104881
|
/* @__PURE__ */ jsxRuntimeExports.jsx(
|
|
104864
104882
|
TailwindDateRangePicker,
|
|
104865
104883
|
{
|
|
104866
|
-
defaultValue: typeof timeRange === "string" ? timeRange === "7 days" ? "7d" : timeRange === "30 days" ? "30d" : timeRange === "90 days" ? "30d" : timeRange === "24 hours" ? "
|
|
104884
|
+
defaultValue: typeof timeRange === "string" ? timeRange === "7 days" ? "7d" : timeRange === "30 days" ? "30d" : timeRange === "90 days" ? "30d" : timeRange === "24 hours" ? "24h" : timeRange === "1 hour" ? "24h" : "7d" : "7d",
|
|
104867
104885
|
value: typeof timeRange === "object" ? timeRange : void 0,
|
|
104868
104886
|
presetLabel: timeRangePresetLabel,
|
|
104869
104887
|
onDateRangeChange: handleDateRangeChange,
|
|
104870
|
-
className: "w-[
|
|
104888
|
+
className: "w-[190px]"
|
|
104871
104889
|
}
|
|
104872
104890
|
),
|
|
104873
104891
|
/* @__PURE__ */ jsxRuntimeExports.jsxs(
|
|
@@ -106549,27 +106567,16 @@ function TraceTree({
|
|
|
106549
106567
|
showTraceId && /* @__PURE__ */ jsxRuntimeExports.jsxs("div", { className: "flex gap-[8px] items-center justify-end px-0 py-[4px] w-full", children: [
|
|
106550
106568
|
/* @__PURE__ */ jsxRuntimeExports.jsx("span", { className: "text-[10px] leading-[12px] text-[#98A2B3]", children: "Trace ID" }),
|
|
106551
106569
|
/* @__PURE__ */ jsxRuntimeExports.jsx("span", { className: "font-medium text-[10px] leading-[12px] text-[#667085]", children: trace.id }),
|
|
106552
|
-
/* @__PURE__ */ jsxRuntimeExports.
|
|
106553
|
-
|
|
106554
|
-
|
|
106555
|
-
|
|
106556
|
-
|
|
106557
|
-
|
|
106558
|
-
|
|
106559
|
-
|
|
106560
|
-
|
|
106561
|
-
|
|
106562
|
-
),
|
|
106563
|
-
/* @__PURE__ */ jsxRuntimeExports.jsx(
|
|
106564
|
-
"button",
|
|
106565
|
-
{
|
|
106566
|
-
className: "p-0 opacity-60 hover:opacity-100 transition-opacity",
|
|
106567
|
-
title: "Open trace details",
|
|
106568
|
-
"data-test-id": `trace-tree-external-link-btn-${trace.id}`,
|
|
106569
|
-
children: /* @__PURE__ */ jsxRuntimeExports.jsx(ExternalLink, { className: "w-[12px] h-[12px] text-[#98A2B3]" })
|
|
106570
|
-
}
|
|
106571
|
-
)
|
|
106572
|
-
] })
|
|
106570
|
+
/* @__PURE__ */ jsxRuntimeExports.jsx(
|
|
106571
|
+
"button",
|
|
106572
|
+
{
|
|
106573
|
+
onClick: handleCopyTraceId,
|
|
106574
|
+
className: "p-0 opacity-60 hover:opacity-100 transition-opacity",
|
|
106575
|
+
title: "Copy trace ID",
|
|
106576
|
+
"data-test-id": `trace-tree-copy-id-btn-${trace.id}`,
|
|
106577
|
+
children: /* @__PURE__ */ jsxRuntimeExports.jsx(Copy, { className: `w-[12px] h-[12px] ${copied ? "text-[#17B26A]" : "text-[#98A2B3]"}` })
|
|
106578
|
+
}
|
|
106579
|
+
)
|
|
106573
106580
|
] })
|
|
106574
106581
|
] });
|
|
106575
106582
|
}
|
|
@@ -106591,19 +106598,19 @@ const CopyButton$1 = ({
|
|
|
106591
106598
|
case "sm":
|
|
106592
106599
|
return {
|
|
106593
106600
|
button: "p-1",
|
|
106594
|
-
|
|
106601
|
+
icon: "w-[12px] h-[12px]",
|
|
106595
106602
|
tooltip: "text-xs py-1 px-2"
|
|
106596
106603
|
};
|
|
106597
106604
|
case "lg":
|
|
106598
106605
|
return {
|
|
106599
106606
|
button: "p-2",
|
|
106600
|
-
|
|
106607
|
+
icon: "w-[20px] h-[20px]",
|
|
106601
106608
|
tooltip: "text-sm py-2 px-3"
|
|
106602
106609
|
};
|
|
106603
106610
|
default:
|
|
106604
106611
|
return {
|
|
106605
106612
|
button: "p-1.5",
|
|
106606
|
-
|
|
106613
|
+
icon: "w-[16px] h-[16px]",
|
|
106607
106614
|
tooltip: "text-xs py-1 px-2"
|
|
106608
106615
|
};
|
|
106609
106616
|
}
|
|
@@ -106666,7 +106673,7 @@ const CopyButton$1 = ({
|
|
|
106666
106673
|
onClick: copyToClipboard2,
|
|
106667
106674
|
className: `${sizeClasses2.button} hover:bg-gray-100 rounded transition-colors ${className}`,
|
|
106668
106675
|
title,
|
|
106669
|
-
children: /* @__PURE__ */ jsxRuntimeExports.jsx(Copy, { className:
|
|
106676
|
+
children: /* @__PURE__ */ jsxRuntimeExports.jsx(Copy, { className: `${sizeClasses2.icon} text-gray-400 ${iconClassName}`, style: iconStyle })
|
|
106670
106677
|
}
|
|
106671
106678
|
),
|
|
106672
106679
|
/* @__PURE__ */ jsxRuntimeExports.jsx(
|
|
@@ -107800,7 +107807,7 @@ const DataModal = ({
|
|
|
107800
107807
|
/* @__PURE__ */ jsxRuntimeExports.jsxs("div", { className: "flex items-center justify-between p-4 border-b border-gray-700", children: [
|
|
107801
107808
|
/* @__PURE__ */ jsxRuntimeExports.jsxs("div", { className: "flex items-center gap-4", children: [
|
|
107802
107809
|
/* @__PURE__ */ jsxRuntimeExports.jsxs("div", { className: "flex items-center gap-2", children: [
|
|
107803
|
-
/* @__PURE__ */ jsxRuntimeExports.jsx(FileCode, {
|
|
107810
|
+
/* @__PURE__ */ jsxRuntimeExports.jsx(FileCode, { className: "w-[20px] h-[20px] text-[#9CA3AF]" }),
|
|
107804
107811
|
/* @__PURE__ */ jsxRuntimeExports.jsx("h3", { className: "text-lg font-semibold text-gray-100", children: title })
|
|
107805
107812
|
] }),
|
|
107806
107813
|
isValidJson && /* @__PURE__ */ jsxRuntimeExports.jsxs("div", { className: "flex items-center gap-1 ml-4 pl-4 border-l border-gray-700", children: [
|
|
@@ -107810,7 +107817,7 @@ const DataModal = ({
|
|
|
107810
107817
|
onClick: () => setViewMode("interactive"),
|
|
107811
107818
|
className: `p-1.5 hover:bg-gray-700 rounded transition-colors ${viewMode === "interactive" ? "bg-gray-700" : ""}`,
|
|
107812
107819
|
title: "Collapsed JSON view (fold/unfold)",
|
|
107813
|
-
children: /* @__PURE__ */ jsxRuntimeExports.jsx(ListTree, {
|
|
107820
|
+
children: /* @__PURE__ */ jsxRuntimeExports.jsx(ListTree, { className: "w-[16px] h-[16px] text-[#9CA3AF]" })
|
|
107814
107821
|
}
|
|
107815
107822
|
),
|
|
107816
107823
|
/* @__PURE__ */ jsxRuntimeExports.jsx(
|
|
@@ -107819,7 +107826,7 @@ const DataModal = ({
|
|
|
107819
107826
|
onClick: () => setViewMode("plain"),
|
|
107820
107827
|
className: `p-1.5 hover:bg-gray-700 rounded transition-colors ${viewMode === "plain" ? "bg-gray-700" : ""}`,
|
|
107821
107828
|
title: "Plain JSON view",
|
|
107822
|
-
children: /* @__PURE__ */ jsxRuntimeExports.jsx(AlignLeft, {
|
|
107829
|
+
children: /* @__PURE__ */ jsxRuntimeExports.jsx(AlignLeft, { className: "w-[16px] h-[16px] text-[#9CA3AF]" })
|
|
107823
107830
|
}
|
|
107824
107831
|
)
|
|
107825
107832
|
] })
|
|
@@ -107840,7 +107847,7 @@ const DataModal = ({
|
|
|
107840
107847
|
onClick: onClose,
|
|
107841
107848
|
className: "p-2 hover:bg-gray-700 rounded-lg transition-colors",
|
|
107842
107849
|
title: "Close",
|
|
107843
|
-
children: /* @__PURE__ */ jsxRuntimeExports.jsx(X, {
|
|
107850
|
+
children: /* @__PURE__ */ jsxRuntimeExports.jsx(X, { className: "w-[16px] h-[16px] text-[#9CA3AF]" })
|
|
107844
107851
|
}
|
|
107845
107852
|
)
|
|
107846
107853
|
] })
|
|
@@ -107918,7 +107925,7 @@ const JsonViewer = ({
|
|
|
107918
107925
|
onClick: () => onToggleKey == null ? void 0 : onToggleKey(fullPath),
|
|
107919
107926
|
className: `flex items-center gap-1 p-1 rounded transition-colors ${darkMode ? "hover:bg-gray-700" : "hover:bg-gray-100"}`,
|
|
107920
107927
|
children: [
|
|
107921
|
-
isExpanded ? /* @__PURE__ */ jsxRuntimeExports.jsx(ChevronDown, {
|
|
107928
|
+
isExpanded ? /* @__PURE__ */ jsxRuntimeExports.jsx(ChevronDown, { className: `w-[12px] h-[12px] ${darkMode ? "text-[#6B7280]" : "text-[#9CA3AF]"}` }) : /* @__PURE__ */ jsxRuntimeExports.jsx(ChevronRight, { className: `w-[12px] h-[12px] ${darkMode ? "text-[#6B7280]" : "text-[#9CA3AF]"}` }),
|
|
107922
107929
|
/* @__PURE__ */ jsxRuntimeExports.jsxs("span", { className: `text-xs ${darkMode ? "text-gray-300" : "text-gray-600"}`, children: [
|
|
107923
107930
|
"Array[",
|
|
107924
107931
|
value.length,
|
|
@@ -107953,7 +107960,7 @@ const JsonViewer = ({
|
|
|
107953
107960
|
onClick: () => onToggleKey == null ? void 0 : onToggleKey(fullPath),
|
|
107954
107961
|
className: `flex items-center gap-1 p-1 rounded transition-colors ${darkMode ? "hover:bg-gray-700" : "hover:bg-gray-100"}`,
|
|
107955
107962
|
children: [
|
|
107956
|
-
isExpanded ? /* @__PURE__ */ jsxRuntimeExports.jsx(ChevronDown, {
|
|
107963
|
+
isExpanded ? /* @__PURE__ */ jsxRuntimeExports.jsx(ChevronDown, { className: `w-[12px] h-[12px] ${darkMode ? "text-[#6B7280]" : "text-[#9CA3AF]"}` }) : /* @__PURE__ */ jsxRuntimeExports.jsx(ChevronRight, { className: `w-[12px] h-[12px] ${darkMode ? "text-[#6B7280]" : "text-[#9CA3AF]"}` }),
|
|
107957
107964
|
/* @__PURE__ */ jsxRuntimeExports.jsxs("span", { className: `text-xs ${darkMode ? "text-gray-300" : "text-gray-600"}`, children: [
|
|
107958
107965
|
"Object ",
|
|
107959
107966
|
"{",
|
|
@@ -108120,17 +108127,17 @@ const DataViewer = ({
|
|
|
108120
108127
|
] });
|
|
108121
108128
|
}
|
|
108122
108129
|
return /* @__PURE__ */ jsxRuntimeExports.jsxs(jsxRuntimeExports.Fragment, { children: [
|
|
108123
|
-
/* @__PURE__ */ jsxRuntimeExports.jsxs("div", { className: `${darkMode ? "bg-gray-800 border-gray-700" : "bg-white border-gray-200"} border rounded-md overflow-hidden ${className}`, "data-id": "data_viewer_root", children: [
|
|
108124
|
-
showHeader && /* @__PURE__ */ jsxRuntimeExports.jsxs("div", { className: "bg-[#F9FAFB] border_secondary_bottom px-4 py-2 flex items-center justify-between", "data-id": "data_viewer_header", children: [
|
|
108125
|
-
isValidJson && /* @__PURE__ */ jsxRuntimeExports.jsxs("div", { className: "flex items-center gap-2", "data-id": "data_viewer_header_view_toggles", children: [
|
|
108130
|
+
/* @__PURE__ */ jsxRuntimeExports.jsxs("div", { className: `${darkMode ? "bg-gray-800 border-gray-700" : "bg-white border-gray-200"} border rounded-md overflow-hidden ${className}`, "data-test-id": "data_viewer_root", children: [
|
|
108131
|
+
showHeader && /* @__PURE__ */ jsxRuntimeExports.jsxs("div", { className: "bg-[#F9FAFB] border_secondary_bottom px-4 py-2 flex items-center justify-between", "data-test-id": "data_viewer_header", children: [
|
|
108132
|
+
isValidJson && /* @__PURE__ */ jsxRuntimeExports.jsxs("div", { className: "flex items-center gap-2", "data-test-id": "data_viewer_header_view_toggles", children: [
|
|
108126
108133
|
/* @__PURE__ */ jsxRuntimeExports.jsx(
|
|
108127
108134
|
"button",
|
|
108128
108135
|
{
|
|
108129
108136
|
onClick: () => handleViewModeChange("interactive"),
|
|
108130
108137
|
className: `p-1 hover:bg-gray-200 rounded transition-colors ${currentViewMode === "interactive" ? "bg-gray-200" : ""}`,
|
|
108131
108138
|
title: "Collapsed JSON view (fold/unfold)",
|
|
108132
|
-
"data-id": "data_viewer_header_btn_interactive",
|
|
108133
|
-
children: /* @__PURE__ */ jsxRuntimeExports.jsx(ListTree, {
|
|
108139
|
+
"data-test-id": "data_viewer_header_btn_interactive",
|
|
108140
|
+
children: /* @__PURE__ */ jsxRuntimeExports.jsx(ListTree, { className: "w-[16px] h-[16px] text-[#98A2B3]" })
|
|
108134
108141
|
}
|
|
108135
108142
|
),
|
|
108136
108143
|
/* @__PURE__ */ jsxRuntimeExports.jsx(
|
|
@@ -108139,21 +108146,21 @@ const DataViewer = ({
|
|
|
108139
108146
|
onClick: () => handleViewModeChange("plain"),
|
|
108140
108147
|
className: `p-1 hover:bg-gray-200 rounded transition-colors ${currentViewMode === "plain" ? "bg-gray-200" : ""}`,
|
|
108141
108148
|
title: "Plain JSON view",
|
|
108142
|
-
"data-id": "data_viewer_header_btn_plain",
|
|
108143
|
-
children: /* @__PURE__ */ jsxRuntimeExports.jsx(AlignLeft, {
|
|
108149
|
+
"data-test-id": "data_viewer_header_btn_plain",
|
|
108150
|
+
children: /* @__PURE__ */ jsxRuntimeExports.jsx(AlignLeft, { className: "w-[16px] h-[16px] text-[#98A2B3]" })
|
|
108144
108151
|
}
|
|
108145
108152
|
)
|
|
108146
108153
|
] }),
|
|
108147
|
-
/* @__PURE__ */ jsxRuntimeExports.jsx("div", { className: "flex-1", "data-id": "data_viewer_header_spacer" }),
|
|
108148
|
-
/* @__PURE__ */ jsxRuntimeExports.jsxs("div", { className: "flex items-center gap-2", "data-id": "data_viewer_header_actions", children: [
|
|
108154
|
+
/* @__PURE__ */ jsxRuntimeExports.jsx("div", { className: "flex-1", "data-test-id": "data_viewer_header_spacer" }),
|
|
108155
|
+
/* @__PURE__ */ jsxRuntimeExports.jsxs("div", { className: "flex items-center gap-2", "data-test-id": "data_viewer_header_actions", children: [
|
|
108149
108156
|
/* @__PURE__ */ jsxRuntimeExports.jsx(
|
|
108150
108157
|
"button",
|
|
108151
108158
|
{
|
|
108152
108159
|
onClick: handleExpand,
|
|
108153
108160
|
className: "p-1 hover:bg-gray-200 rounded transition-colors",
|
|
108154
108161
|
title: "Expand to full screen",
|
|
108155
|
-
"data-id": "data_viewer_header_btn_expand",
|
|
108156
|
-
children: /* @__PURE__ */ jsxRuntimeExports.jsx(Maximize2, {
|
|
108162
|
+
"data-test-id": "data_viewer_header_btn_expand",
|
|
108163
|
+
children: /* @__PURE__ */ jsxRuntimeExports.jsx(Maximize2, { className: "w-[16px] h-[16px] text-[#98A2B3]" })
|
|
108157
108164
|
}
|
|
108158
108165
|
),
|
|
108159
108166
|
/* @__PURE__ */ jsxRuntimeExports.jsx(
|
|
@@ -108172,7 +108179,7 @@ const DataViewer = ({
|
|
|
108172
108179
|
{
|
|
108173
108180
|
className: `${padding ? padding : "p-3"} overflow-auto ${darkMode ? "bg-gray-800" : "bg-white"}`,
|
|
108174
108181
|
style: { maxHeight },
|
|
108175
|
-
"data-id": "data_viewer_content",
|
|
108182
|
+
"data-test-id": "data_viewer_content",
|
|
108176
108183
|
children: [
|
|
108177
108184
|
isValidJson ? currentViewMode === "interactive" ? useEnhancedJsonView ? /* @__PURE__ */ jsxRuntimeExports.jsx(
|
|
108178
108185
|
JsonView,
|
|
@@ -108200,7 +108207,7 @@ const DataViewer = ({
|
|
|
108200
108207
|
darkMode
|
|
108201
108208
|
}
|
|
108202
108209
|
) : /* @__PURE__ */ jsxRuntimeExports.jsx("div", { className: `text-xs whitespace-pre font-mono ${darkMode ? "text-gray-300" : "text-[#344054]"}`, children: stringifyJsonNode(parsedData) }) : /* @__PURE__ */ jsxRuntimeExports.jsx("div", { className: `text-xs whitespace-pre-wrap font-mono ${darkMode ? "text-gray-300" : "text-[#344054]"}`, children: displayContent }),
|
|
108203
|
-
!displayContent && displayContent !== 0 && displayContent !== false && /* @__PURE__ */ jsxRuntimeExports.jsx("div", { className: `text-center text-sm py-8 ${darkMode ? "text-gray-500" : "text-gray-400"}`, "data-id": "data_viewer_empty_state", children: "No data available" })
|
|
108210
|
+
!displayContent && displayContent !== 0 && displayContent !== false && /* @__PURE__ */ jsxRuntimeExports.jsx("div", { className: `text-center text-sm py-8 ${darkMode ? "text-gray-500" : "text-gray-400"}`, "data-test-id": "data_viewer_empty_state", children: "No data available" })
|
|
108204
108211
|
]
|
|
108205
108212
|
}
|
|
108206
108213
|
)
|
|
@@ -109193,45 +109200,61 @@ function DetailPage({
|
|
|
109193
109200
|
] })
|
|
109194
109201
|
] }),
|
|
109195
109202
|
/* @__PURE__ */ jsxRuntimeExports.jsxs("div", { className: "flex-1 flex overflow-hidden", children: [
|
|
109196
|
-
/* @__PURE__ */ jsxRuntimeExports.
|
|
109197
|
-
|
|
109198
|
-
|
|
109199
|
-
|
|
109200
|
-
|
|
109201
|
-
|
|
109202
|
-
const filteredObservations = getFilteredObservations(trace.id, observations);
|
|
109203
|
-
const autoExpandIds = index === 0 ? getAutoExpandIds(trace.id, filteredObservations) : void 0;
|
|
109204
|
-
return /* @__PURE__ */ jsxRuntimeExports.jsx(
|
|
109205
|
-
TraceTree,
|
|
109206
|
-
{
|
|
109207
|
-
trace,
|
|
109208
|
-
observations: filteredObservations,
|
|
109209
|
-
isExpanded: mode === "trace" || index === 0,
|
|
109210
|
-
selectedNodeId: selectedNode && "traceId" in selectedNode ? selectedNode.id : null,
|
|
109211
|
-
onNodeSelect: handleNodeSelect,
|
|
109212
|
-
onExpandToggle: () => handleTraceExpand(trace.id, trace.timestamp),
|
|
109213
|
-
showTraceId: mode === "session",
|
|
109214
|
-
isLoading: isLoadingObservations,
|
|
109215
|
-
defaultExpandedNodeIds: autoExpandIds
|
|
109216
|
-
},
|
|
109217
|
-
trace.id
|
|
109218
|
-
);
|
|
109219
|
-
}),
|
|
109220
|
-
mode === "session" && progressiveState.pendingTraceIds.length > 0 && /* @__PURE__ */ jsxRuntimeExports.jsx(jsxRuntimeExports.Fragment, { children: progressiveState.pendingTraceIds.map((pendingTraceId, index) => {
|
|
109221
|
-
const isFirstPending = index === 0 && !progressiveState.firstTraceLoaded;
|
|
109222
|
-
return /* @__PURE__ */ jsxRuntimeExports.jsx(
|
|
109223
|
-
TreeSkeleton,
|
|
109203
|
+
/* @__PURE__ */ jsxRuntimeExports.jsxs("div", { className: "w-[480px] min-w-[400px] max-w-[600px] border-r border-[#E4E7EC] flex flex-col bg-[#F9FAFB] overflow-auto", children: [
|
|
109204
|
+
mode === "session" && sessionId && /* @__PURE__ */ jsxRuntimeExports.jsxs("div", { className: "flex items-center gap-[8px] px-[24px] py-[4px] bg-white border-b border-[#EAECF0]", children: [
|
|
109205
|
+
/* @__PURE__ */ jsxRuntimeExports.jsx("span", { className: "text-[12px] text-[#667085]", children: "Session ID" }),
|
|
109206
|
+
/* @__PURE__ */ jsxRuntimeExports.jsx("span", { className: "font-mono text-[12px] text-[#344054]", children: sessionId }),
|
|
109207
|
+
/* @__PURE__ */ jsxRuntimeExports.jsx(
|
|
109208
|
+
"button",
|
|
109224
109209
|
{
|
|
109225
|
-
|
|
109226
|
-
|
|
109227
|
-
|
|
109228
|
-
|
|
109229
|
-
className: "
|
|
109230
|
-
}
|
|
109231
|
-
|
|
109232
|
-
|
|
109233
|
-
|
|
109234
|
-
|
|
109210
|
+
onClick: handleCopyId,
|
|
109211
|
+
className: "p-[2px] rounded-[4px] hover:bg-[#F2F4F7] transition-opacity opacity-60 hover:opacity-100",
|
|
109212
|
+
title: "Copy Session ID",
|
|
109213
|
+
"data-test-id": "session-id-copy-btn",
|
|
109214
|
+
children: /* @__PURE__ */ jsxRuntimeExports.jsx(Copy, { className: `w-[12px] h-[12px] ${copiedId ? "text-[#17B26A]" : "text-[#98A2B3]"}` })
|
|
109215
|
+
}
|
|
109216
|
+
)
|
|
109217
|
+
] }),
|
|
109218
|
+
/* @__PURE__ */ jsxRuntimeExports.jsxs("div", { className: "flex-1 p-[16px]", children: [
|
|
109219
|
+
traces.length === 0 && loadingState === "success" && progressiveState.traceCount === 0 && /* @__PURE__ */ jsxRuntimeExports.jsx("div", { className: "py-[32px] text-center text-[13px] text-[#667085]", children: "No traces available" }),
|
|
109220
|
+
traces.map((trace, index) => {
|
|
109221
|
+
var _a, _b, _c, _d;
|
|
109222
|
+
const observations = ((_b = (_a = traceObservations[trace.id]) == null ? void 0 : _a.observations) == null ? void 0 : _b.length) > 0 ? traceObservations[trace.id].observations : mode === "trace" ? (traceData == null ? void 0 : traceData.observations) || [] : [];
|
|
109223
|
+
const isLoadingObservations = ((_c = traceObservations[trace.id]) == null ? void 0 : _c.loading) || mode === "trace" && (((_d = traceData == null ? void 0 : traceData.observations) == null ? void 0 : _d.length) || 0) === 0;
|
|
109224
|
+
const filteredObservations = getFilteredObservations(trace.id, observations);
|
|
109225
|
+
const autoExpandIds = index === 0 ? getAutoExpandIds(trace.id, filteredObservations) : void 0;
|
|
109226
|
+
return /* @__PURE__ */ jsxRuntimeExports.jsx(
|
|
109227
|
+
TraceTree,
|
|
109228
|
+
{
|
|
109229
|
+
trace,
|
|
109230
|
+
observations: filteredObservations,
|
|
109231
|
+
isExpanded: mode === "trace" || index === 0,
|
|
109232
|
+
selectedNodeId: selectedNode && "traceId" in selectedNode ? selectedNode.id : null,
|
|
109233
|
+
onNodeSelect: handleNodeSelect,
|
|
109234
|
+
onExpandToggle: () => handleTraceExpand(trace.id, trace.timestamp),
|
|
109235
|
+
showTraceId: mode === "session",
|
|
109236
|
+
isLoading: isLoadingObservations,
|
|
109237
|
+
defaultExpandedNodeIds: autoExpandIds
|
|
109238
|
+
},
|
|
109239
|
+
trace.id
|
|
109240
|
+
);
|
|
109241
|
+
}),
|
|
109242
|
+
mode === "session" && progressiveState.pendingTraceIds.length > 0 && /* @__PURE__ */ jsxRuntimeExports.jsx(jsxRuntimeExports.Fragment, { children: progressiveState.pendingTraceIds.map((pendingTraceId, index) => {
|
|
109243
|
+
const isFirstPending = index === 0 && !progressiveState.firstTraceLoaded;
|
|
109244
|
+
return /* @__PURE__ */ jsxRuntimeExports.jsx(
|
|
109245
|
+
TreeSkeleton,
|
|
109246
|
+
{
|
|
109247
|
+
traceCount: 1,
|
|
109248
|
+
observationsPerTrace: 4,
|
|
109249
|
+
isExpanded: isFirstPending,
|
|
109250
|
+
showTraceId: true,
|
|
109251
|
+
className: "!p-0"
|
|
109252
|
+
},
|
|
109253
|
+
`skeleton-${pendingTraceId}`
|
|
109254
|
+
);
|
|
109255
|
+
}) })
|
|
109256
|
+
] })
|
|
109257
|
+
] }),
|
|
109235
109258
|
!selectedNode && !hasAutoSelected ? /* @__PURE__ */ jsxRuntimeExports.jsx(NodeDetailSkeleton, { showFullSummary: true }) : /* @__PURE__ */ jsxRuntimeExports.jsx(NodeDetailPanel, { node: selectedNode, nodeType, apiConfig })
|
|
109236
109259
|
] })
|
|
109237
109260
|
] });
|
|
@@ -110385,7 +110408,8 @@ function TracesListContent(props) {
|
|
|
110385
110408
|
newMap.set(traceId, {
|
|
110386
110409
|
input: detail["input"],
|
|
110387
110410
|
output: detail["output"],
|
|
110388
|
-
totalCost: detail["totalCost"]
|
|
110411
|
+
totalCost: detail["totalCost"],
|
|
110412
|
+
envId: detail["envId"]
|
|
110389
110413
|
});
|
|
110390
110414
|
return newMap;
|
|
110391
110415
|
});
|
|
@@ -110496,7 +110520,14 @@ function TracesListContent(props) {
|
|
|
110496
110520
|
headerName: "Environment",
|
|
110497
110521
|
width: 150,
|
|
110498
110522
|
hide: false,
|
|
110499
|
-
cellRenderer: (params) =>
|
|
110523
|
+
cellRenderer: (params) => {
|
|
110524
|
+
const detailData = detailedTraceData.get(params.data.id);
|
|
110525
|
+
const envId = detailData == null ? void 0 : detailData.envId;
|
|
110526
|
+
if (envId === void 0) {
|
|
110527
|
+
return /* @__PURE__ */ jsxRuntimeExports.jsx("span", { className: "text-xs text-gray-400 italic", children: "Loading..." });
|
|
110528
|
+
}
|
|
110529
|
+
return /* @__PURE__ */ jsxRuntimeExports.jsx(EnvironmentNameCell, { envId });
|
|
110530
|
+
}
|
|
110500
110531
|
}
|
|
110501
110532
|
);
|
|
110502
110533
|
baseColumns.push(
|
|
@@ -110856,6 +110887,7 @@ function TracesListContent(props) {
|
|
|
110856
110887
|
title: "Traces",
|
|
110857
110888
|
description: "Inspect execution traces to analyze model reasoning, tool usage, and performance insights.",
|
|
110858
110889
|
searchPlaceholder: "Search...",
|
|
110890
|
+
showSearch: totalCount > 0 || searchTerm.length > 0,
|
|
110859
110891
|
searchConfig: {
|
|
110860
110892
|
metadataSearchFields: ["ID", "Input", "User ID"],
|
|
110861
110893
|
updateQuery: handleSearch,
|
|
@@ -113427,15 +113459,15 @@ function DebugCard({
|
|
|
113427
113459
|
};
|
|
113428
113460
|
return (
|
|
113429
113461
|
// bg-white w-full border-t border-gray-200
|
|
113430
|
-
/* @__PURE__ */ jsxRuntimeExports.jsxs("div", { className: "bg-white w-full", "data-id": `debug_card_${node.id}`, children: [
|
|
113462
|
+
/* @__PURE__ */ jsxRuntimeExports.jsxs("div", { className: "bg-white w-full", "data-test-id": `debug_card_${node.id}`, children: [
|
|
113431
113463
|
/* @__PURE__ */ jsxRuntimeExports.jsx(
|
|
113432
113464
|
"div",
|
|
113433
113465
|
{
|
|
113434
113466
|
className: `flex items-center pl-[8px] pr-[8px] relative transition-colors cursor-pointer w-full
|
|
113435
113467
|
${isSelected ? "" : ""}`,
|
|
113436
113468
|
onClick: handleNodeClick,
|
|
113437
|
-
"data-id": `debug_card_header_${node.id}`,
|
|
113438
|
-
children: /* @__PURE__ */ jsxRuntimeExports.jsxs("div", { className: "flex items-center gap-[10px] w-full", "data-id": `debug_card_header_content_${node.id}`, children: [
|
|
113469
|
+
"data-test-id": `debug_card_header_${node.id}`,
|
|
113470
|
+
children: /* @__PURE__ */ jsxRuntimeExports.jsxs("div", { className: "flex items-center gap-[10px] w-full", "data-test-id": `debug_card_header_content_${node.id}`, children: [
|
|
113439
113471
|
/* @__PURE__ */ jsxRuntimeExports.jsx(
|
|
113440
113472
|
"div",
|
|
113441
113473
|
{
|
|
@@ -113449,7 +113481,7 @@ function DebugCard({
|
|
|
113449
113481
|
}
|
|
113450
113482
|
},
|
|
113451
113483
|
title: hasChildren ? isExpanded ? "Collapse" : "Expand" : "Show details",
|
|
113452
|
-
"data-id": `debug_card_toggle_${node.id}`,
|
|
113484
|
+
"data-test-id": `debug_card_toggle_${node.id}`,
|
|
113453
113485
|
children: /* @__PURE__ */ jsxRuntimeExports.jsx(
|
|
113454
113486
|
ChevronRight,
|
|
113455
113487
|
{
|
|
@@ -113458,18 +113490,18 @@ function DebugCard({
|
|
|
113458
113490
|
)
|
|
113459
113491
|
}
|
|
113460
113492
|
),
|
|
113461
|
-
/* @__PURE__ */ jsxRuntimeExports.jsxs("div", { className: "flex items-center gap-[8px] w-full py-[8px] border-b border-gray-200", "data-id": `debug_card_node_info_${node.id}`, children: [
|
|
113462
|
-
/* @__PURE__ */ jsxRuntimeExports.jsx("div", { className: "flex-shrink-0 rounded-[8px] bg-[#B2DDFF]", "data-id": `debug_card_node_icon_${node.id}`, children: getNodeIcon() }),
|
|
113493
|
+
/* @__PURE__ */ jsxRuntimeExports.jsxs("div", { className: "flex items-center gap-[8px] w-full py-[8px] border-b border-gray-200", "data-test-id": `debug_card_node_info_${node.id}`, children: [
|
|
113494
|
+
/* @__PURE__ */ jsxRuntimeExports.jsx("div", { className: "flex-shrink-0 rounded-[8px] bg-[#B2DDFF]", "data-test-id": `debug_card_node_icon_${node.id}`, children: getNodeIcon() }),
|
|
113463
113495
|
/* @__PURE__ */ jsxRuntimeExports.jsx(
|
|
113464
113496
|
"span",
|
|
113465
113497
|
{
|
|
113466
113498
|
className: "font-semibold text-gray-900 text-xs truncate w-full",
|
|
113467
113499
|
title: node.type === "llm" ? node.name : void 0,
|
|
113468
|
-
"data-id": `debug_card_node_name_${node.id}`,
|
|
113500
|
+
"data-test-id": `debug_card_node_name_${node.id}`,
|
|
113469
113501
|
children: isGuardrailsNode ? node.type === "GuardrailsInputScan" ? "Input Guardrails Scanner" : "Output Guardrails Scanner" : node.type === "llm" ? "AI Model Call" : node.type === "tool" ? formatToolName(node.name) : node.name
|
|
113470
113502
|
}
|
|
113471
113503
|
),
|
|
113472
|
-
/* @__PURE__ */ jsxRuntimeExports.jsxs("div", { className: "flex items-center gap-[12px] text-[10px] text-gray-500", "data-id": `debug_card_node_metadata_${node.id}`, children: [
|
|
113504
|
+
/* @__PURE__ */ jsxRuntimeExports.jsxs("div", { className: "flex items-center gap-[12px] text-[10px] text-gray-500", "data-test-id": `debug_card_node_metadata_${node.id}`, children: [
|
|
113473
113505
|
node.type === "Agent" && (() => {
|
|
113474
113506
|
var _a;
|
|
113475
113507
|
const llmChild = (_a = node.children) == null ? void 0 : _a.find((child) => child.type === "llm");
|
|
@@ -113479,7 +113511,7 @@ function DebugCard({
|
|
|
113479
113511
|
{
|
|
113480
113512
|
className: "text-[10px] text-gray-500 truncate max-w-[100px]",
|
|
113481
113513
|
title: llmChild.name,
|
|
113482
|
-
"data-id": `debug_card_node_model_name_${node.id}`,
|
|
113514
|
+
"data-test-id": `debug_card_node_model_name_${node.id}`,
|
|
113483
113515
|
children: llmChild.name
|
|
113484
113516
|
}
|
|
113485
113517
|
);
|
|
@@ -113512,7 +113544,7 @@ function DebugCard({
|
|
|
113512
113544
|
title: `Input: ${((_a = llmUsage.input_tokens) == null ? void 0 : _a.toLocaleString()) || 0} tokens
|
|
113513
113545
|
Output: ${((_b = llmUsage.output_tokens) == null ? void 0 : _b.toLocaleString()) || 0} tokens
|
|
113514
113546
|
Total: ${((_c = llmUsage.total_tokens) == null ? void 0 : _c.toLocaleString()) || 0} tokens`,
|
|
113515
|
-
"data-id": `debug_card_node_tokens_${node.id}`,
|
|
113547
|
+
"data-test-id": `debug_card_node_tokens_${node.id}`,
|
|
113516
113548
|
children: [
|
|
113517
113549
|
llmUsage.total_tokens.toLocaleString(),
|
|
113518
113550
|
" Tokens"
|
|
@@ -113522,34 +113554,34 @@ Total: ${((_c = llmUsage.total_tokens) == null ? void 0 : _c.toLocaleString()) |
|
|
|
113522
113554
|
}
|
|
113523
113555
|
return null;
|
|
113524
113556
|
})(),
|
|
113525
|
-
node.duration && /* @__PURE__ */ jsxRuntimeExports.jsxs("div", { className: "flex items-center gap-[4px]", "data-id": `debug_card_node_duration_${node.id}`, children: [
|
|
113557
|
+
node.duration && /* @__PURE__ */ jsxRuntimeExports.jsxs("div", { className: "flex items-center gap-[4px]", "data-test-id": `debug_card_node_duration_${node.id}`, children: [
|
|
113526
113558
|
/* @__PURE__ */ jsxRuntimeExports.jsx(Clock, { className: "w-[12px] h-[12px]" }),
|
|
113527
113559
|
/* @__PURE__ */ jsxRuntimeExports.jsx("span", { className: "text-[10px] text-gray-500 whitespace-nowrap", children: formatDuration(node.duration) })
|
|
113528
113560
|
] })
|
|
113529
113561
|
] }),
|
|
113530
|
-
/* @__PURE__ */ jsxRuntimeExports.jsx("div", { className: "flex-shrink-0", "data-id": `debug_card_node_status_${node.id}`, children: getStatusIcon() })
|
|
113562
|
+
/* @__PURE__ */ jsxRuntimeExports.jsx("div", { className: "flex-shrink-0", "data-test-id": `debug_card_node_status_${node.id}`, children: getStatusIcon() })
|
|
113531
113563
|
] })
|
|
113532
113564
|
] })
|
|
113533
113565
|
}
|
|
113534
113566
|
),
|
|
113535
|
-
isSelected && availableTabs.length > 0 && showDetailView && /* @__PURE__ */ jsxRuntimeExports.jsxs("div", { className: "w-full pl-[32px] relative", "data-id": `debug_card_detail_panel_${node.id}`, children: [
|
|
113536
|
-
/* @__PURE__ */ jsxRuntimeExports.jsx("div", { className: "absolute top-[-40px] left-[16px] w-[1px] border-l border-dashed border-gray-200 h-[calc(100%+40px)] z-[1]", "data-id": `debug_card_detail_panel_connector_${node.id}` }),
|
|
113537
|
-
/* @__PURE__ */ jsxRuntimeExports.jsxs("div", { className: "px-[4px] py-[8px] w-full", "data-id": `debug_card_detail_panel_content_${node.id}`, children: [
|
|
113538
|
-
/* @__PURE__ */ jsxRuntimeExports.jsx("div", { className: "bg-gray-50 rounded-[4px] p-[4px] inline-flex gap-[4px] mb-[8px] border border-gray-200", "data-id": `debug_card_detail_panel_tabs_${node.id}`, children: getTabsForNodeType().map((tab) => /* @__PURE__ */ jsxRuntimeExports.jsx(
|
|
113567
|
+
isSelected && availableTabs.length > 0 && showDetailView && /* @__PURE__ */ jsxRuntimeExports.jsxs("div", { className: "w-full pl-[32px] relative", "data-test-id": `debug_card_detail_panel_${node.id}`, children: [
|
|
113568
|
+
/* @__PURE__ */ jsxRuntimeExports.jsx("div", { className: "absolute top-[-40px] left-[16px] w-[1px] border-l border-dashed border-gray-200 h-[calc(100%+40px)] z-[1]", "data-test-id": `debug_card_detail_panel_connector_${node.id}` }),
|
|
113569
|
+
/* @__PURE__ */ jsxRuntimeExports.jsxs("div", { className: "px-[4px] py-[8px] w-full", "data-test-id": `debug_card_detail_panel_content_${node.id}`, children: [
|
|
113570
|
+
/* @__PURE__ */ jsxRuntimeExports.jsx("div", { className: "bg-gray-50 rounded-[4px] p-[4px] inline-flex gap-[4px] mb-[8px] border border-gray-200", "data-test-id": `debug_card_detail_panel_tabs_${node.id}`, children: getTabsForNodeType().map((tab) => /* @__PURE__ */ jsxRuntimeExports.jsx(
|
|
113539
113571
|
"button",
|
|
113540
113572
|
{
|
|
113541
113573
|
onClick: () => handleTabClick(tab),
|
|
113542
113574
|
className: `px-[8px] py-[4px] text-xs font-medium rounded-[4px] text-gray-500 hover:text-gray-700 hover:shadow-tab hover:bg-white transition-colors ${activeTab === tab ? "bg-white text-gray-900 shadow-tab" : "text-gray-500 hover:text-gray-700 hover:bg-white"}`,
|
|
113543
|
-
"data-id": `debug_card_detail_panel_tab_${node.id}_${tab}`,
|
|
113575
|
+
"data-test-id": `debug_card_detail_panel_tab_${node.id}_${tab}`,
|
|
113544
113576
|
children: tab.charAt(0).toUpperCase() + tab.slice(1)
|
|
113545
113577
|
},
|
|
113546
113578
|
tab
|
|
113547
113579
|
)) }),
|
|
113548
|
-
/* @__PURE__ */ jsxRuntimeExports.jsx("div", { className: "px-[4px]", "data-id": `debug_card_detail_panel_tab_content_${node.id}`, children: renderTabContent() })
|
|
113580
|
+
/* @__PURE__ */ jsxRuntimeExports.jsx("div", { className: "px-[4px]", "data-test-id": `debug_card_detail_panel_tab_content_${node.id}`, children: renderTabContent() })
|
|
113549
113581
|
] })
|
|
113550
113582
|
] }),
|
|
113551
|
-
isExpanded && hasChildren && /* @__PURE__ */ jsxRuntimeExports.jsxs("div", { className: "w-full pl-[32px] relative", "data-id": `debug_card_children_${node.id}`, children: [
|
|
113552
|
-
/* @__PURE__ */ jsxRuntimeExports.jsx("div", { className: "absolute top-[-40px] left-[16px] w-[1px] border-l border-dashed border-gray-200 h-[calc(100%+40px)] z-[1]", "data-id": `debug_card_children_connector_${node.id}` }),
|
|
113583
|
+
isExpanded && hasChildren && /* @__PURE__ */ jsxRuntimeExports.jsxs("div", { className: "w-full pl-[32px] relative", "data-test-id": `debug_card_children_${node.id}`, children: [
|
|
113584
|
+
/* @__PURE__ */ jsxRuntimeExports.jsx("div", { className: "absolute top-[-40px] left-[16px] w-[1px] border-l border-dashed border-gray-200 h-[calc(100%+40px)] z-[1]", "data-test-id": `debug_card_children_connector_${node.id}` }),
|
|
113553
113585
|
node.children.map((child, index) => /* @__PURE__ */ jsxRuntimeExports.jsx(
|
|
113554
113586
|
DebugCard,
|
|
113555
113587
|
{
|
|
@@ -113853,14 +113885,14 @@ const DebugPanel = forwardRef(({
|
|
|
113853
113885
|
return `${tokens} tokens`;
|
|
113854
113886
|
};
|
|
113855
113887
|
if (!sessionTree.runs.length) {
|
|
113856
|
-
return /* @__PURE__ */ jsxRuntimeExports.jsx("div", { className: `flex flex-col h-full ${className}`, "data-id": "debug_panel_empty_state", children: /* @__PURE__ */ jsxRuntimeExports.jsx("div", { className: "flex items-center justify-center h-full", "data-id": "debug_panel_empty_state_content", children: /* @__PURE__ */ jsxRuntimeExports.jsx("p", { className: "text-gray-500 text-sm", "data-id": "debug_panel_empty_state_message", children: "No execution events to display" }) }) });
|
|
113857
|
-
}
|
|
113858
|
-
return /* @__PURE__ */ jsxRuntimeExports.jsx("div", { className: `flex flex-col h-full bg-white ${className}`, "data-id": "debug_panel_root", children: /* @__PURE__ */ jsxRuntimeExports.jsxs("div", { className: "flex flex-col gap-[16px] p-[24px] overflow-y-auto overflow-x-hidden", ref: scrollContainerRef, "data-id": "debug_panel_content", children: [
|
|
113859
|
-
/* @__PURE__ */ jsxRuntimeExports.jsxs("div", { className: "flex items-center w-full gap-[16px]", "data-id": "debug_panel_session_header", children: [
|
|
113860
|
-
/* @__PURE__ */ jsxRuntimeExports.jsx("div", { className: "text-xs text-gray-400 whitespace-nowrap flex-shrink-0", "data-id": "debug_panel_session_header_label", children: "Session initiated" }),
|
|
113861
|
-
/* @__PURE__ */ jsxRuntimeExports.jsx("div", { className: "flex-1 h-[1px] border-t border-dashed border-gray-300 w-full", "data-id": "debug_panel_session_header_divider" }),
|
|
113862
|
-
/* @__PURE__ */ jsxRuntimeExports.jsxs("div", { className: "flex items-center gap-2 text-xs text-gray-400 flex-shrink-0", "data-id": "debug_panel_session_header_actions", children: [
|
|
113863
|
-
/* @__PURE__ */ jsxRuntimeExports.jsx("span", { "data-id": "debug_panel_session_id", children: sessionTree.sessionId }),
|
|
113888
|
+
return /* @__PURE__ */ jsxRuntimeExports.jsx("div", { className: `flex flex-col h-full ${className}`, "data-test-id": "debug_panel_empty_state", children: /* @__PURE__ */ jsxRuntimeExports.jsx("div", { className: "flex items-center justify-center h-full", "data-test-id": "debug_panel_empty_state_content", children: /* @__PURE__ */ jsxRuntimeExports.jsx("p", { className: "text-gray-500 text-sm", "data-test-id": "debug_panel_empty_state_message", children: "No execution events to display" }) }) });
|
|
113889
|
+
}
|
|
113890
|
+
return /* @__PURE__ */ jsxRuntimeExports.jsx("div", { className: `flex flex-col h-full bg-white ${className}`, "data-test-id": "debug_panel_root", children: /* @__PURE__ */ jsxRuntimeExports.jsxs("div", { className: "flex flex-col gap-[16px] p-[24px] overflow-y-auto overflow-x-hidden", ref: scrollContainerRef, "data-test-id": "debug_panel_content", children: [
|
|
113891
|
+
/* @__PURE__ */ jsxRuntimeExports.jsxs("div", { className: "flex items-center w-full gap-[16px]", "data-test-id": "debug_panel_session_header", children: [
|
|
113892
|
+
/* @__PURE__ */ jsxRuntimeExports.jsx("div", { className: "text-xs text-gray-400 whitespace-nowrap flex-shrink-0", "data-test-id": "debug_panel_session_header_label", children: "Session initiated" }),
|
|
113893
|
+
/* @__PURE__ */ jsxRuntimeExports.jsx("div", { className: "flex-1 h-[1px] border-t border-dashed border-gray-300 w-full", "data-test-id": "debug_panel_session_header_divider" }),
|
|
113894
|
+
/* @__PURE__ */ jsxRuntimeExports.jsxs("div", { className: "flex items-center gap-2 text-xs text-gray-400 flex-shrink-0", "data-test-id": "debug_panel_session_header_actions", children: [
|
|
113895
|
+
/* @__PURE__ */ jsxRuntimeExports.jsx("span", { "data-test-id": "debug_panel_session_id", children: sessionTree.sessionId }),
|
|
113864
113896
|
/* @__PURE__ */ jsxRuntimeExports.jsx(
|
|
113865
113897
|
CopyButton$1,
|
|
113866
113898
|
{
|
|
@@ -113886,22 +113918,22 @@ const DebugPanel = forwardRef(({
|
|
|
113886
113918
|
}
|
|
113887
113919
|
}
|
|
113888
113920
|
},
|
|
113889
|
-
"data-id": "debug_panel_session_external_link_btn",
|
|
113921
|
+
"data-test-id": "debug_panel_session_external_link_btn",
|
|
113890
113922
|
children: /* @__PURE__ */ jsxRuntimeExports.jsx(ExternalLink, { className: "w-[12px] h-[12px]" })
|
|
113891
113923
|
}
|
|
113892
113924
|
)
|
|
113893
113925
|
] })
|
|
113894
113926
|
] }),
|
|
113895
|
-
showExpansionControls && /* @__PURE__ */ jsxRuntimeExports.jsxs("div", { className: "flex items-center justify-between gap-4 p-3 bg-gray-50 rounded-lg border border-gray-200", "data-id": "debug_panel_expansion_controls", children: [
|
|
113896
|
-
/* @__PURE__ */ jsxRuntimeExports.jsxs("div", { className: "flex items-center gap-2", "data-id": "debug_panel_expansion_controls_buttons", children: [
|
|
113897
|
-
/* @__PURE__ */ jsxRuntimeExports.jsx("span", { className: "text-xs font-medium text-gray-700", "data-id": "debug_panel_expansion_controls_label", children: "Expansion:" }),
|
|
113927
|
+
showExpansionControls && /* @__PURE__ */ jsxRuntimeExports.jsxs("div", { className: "flex items-center justify-between gap-4 p-3 bg-gray-50 rounded-lg border border-gray-200", "data-test-id": "debug_panel_expansion_controls", children: [
|
|
113928
|
+
/* @__PURE__ */ jsxRuntimeExports.jsxs("div", { className: "flex items-center gap-2", "data-test-id": "debug_panel_expansion_controls_buttons", children: [
|
|
113929
|
+
/* @__PURE__ */ jsxRuntimeExports.jsx("span", { className: "text-xs font-medium text-gray-700", "data-test-id": "debug_panel_expansion_controls_label", children: "Expansion:" }),
|
|
113898
113930
|
/* @__PURE__ */ jsxRuntimeExports.jsxs(
|
|
113899
113931
|
"button",
|
|
113900
113932
|
{
|
|
113901
113933
|
onClick: handleExpandAll,
|
|
113902
113934
|
className: "flex items-center gap-1 px-2 py-1 text-xs bg-white hover:bg-gray-50 border border-gray-300 rounded transition-colors",
|
|
113903
113935
|
title: "Expand all nodes",
|
|
113904
|
-
"data-id": "debug_panel_expansion_controls_btn_expand_all",
|
|
113936
|
+
"data-test-id": "debug_panel_expansion_controls_btn_expand_all",
|
|
113905
113937
|
children: [
|
|
113906
113938
|
/* @__PURE__ */ jsxRuntimeExports.jsx(Plus, { className: "w-3 h-3" }),
|
|
113907
113939
|
"Expand All"
|
|
@@ -113914,7 +113946,7 @@ const DebugPanel = forwardRef(({
|
|
|
113914
113946
|
onClick: handleExpandLast,
|
|
113915
113947
|
className: "flex items-center gap-1 px-2 py-1 text-xs bg-white hover:bg-gray-50 border border-gray-300 rounded transition-colors",
|
|
113916
113948
|
title: "Expand only the last execution path",
|
|
113917
|
-
"data-id": "debug_panel_expansion_controls_btn_expand_last",
|
|
113949
|
+
"data-test-id": "debug_panel_expansion_controls_btn_expand_last",
|
|
113918
113950
|
children: [
|
|
113919
113951
|
/* @__PURE__ */ jsxRuntimeExports.jsx(Expand, { className: "w-3 h-3" }),
|
|
113920
113952
|
"Expand Last"
|
|
@@ -113927,7 +113959,7 @@ const DebugPanel = forwardRef(({
|
|
|
113927
113959
|
onClick: handleCollapseAll,
|
|
113928
113960
|
className: "flex items-center gap-1 px-2 py-1 text-xs bg-white hover:bg-gray-50 border border-gray-300 rounded transition-colors",
|
|
113929
113961
|
title: "Collapse all nodes",
|
|
113930
|
-
"data-id": "debug_panel_expansion_controls_btn_collapse_all",
|
|
113962
|
+
"data-test-id": "debug_panel_expansion_controls_btn_collapse_all",
|
|
113931
113963
|
children: [
|
|
113932
113964
|
/* @__PURE__ */ jsxRuntimeExports.jsx(Minus, { className: "w-3 h-3" }),
|
|
113933
113965
|
"Collapse All"
|
|
@@ -113935,8 +113967,8 @@ const DebugPanel = forwardRef(({
|
|
|
113935
113967
|
}
|
|
113936
113968
|
)
|
|
113937
113969
|
] }),
|
|
113938
|
-
/* @__PURE__ */ jsxRuntimeExports.jsxs("div", { className: "flex items-center gap-2", "data-id": "debug_panel_expansion_controls_live_mode", children: [
|
|
113939
|
-
/* @__PURE__ */ jsxRuntimeExports.jsx("span", { className: "text-xs font-medium text-gray-700", "data-id": "debug_panel_expansion_controls_live_mode_label", children: "Live Mode:" }),
|
|
113970
|
+
/* @__PURE__ */ jsxRuntimeExports.jsxs("div", { className: "flex items-center gap-2", "data-test-id": "debug_panel_expansion_controls_live_mode", children: [
|
|
113971
|
+
/* @__PURE__ */ jsxRuntimeExports.jsx("span", { className: "text-xs font-medium text-gray-700", "data-test-id": "debug_panel_expansion_controls_live_mode_label", children: "Live Mode:" }),
|
|
113940
113972
|
/* @__PURE__ */ jsxRuntimeExports.jsxs(
|
|
113941
113973
|
"select",
|
|
113942
113974
|
{
|
|
@@ -113944,7 +113976,7 @@ const DebugPanel = forwardRef(({
|
|
|
113944
113976
|
onChange: (e3) => setLiveExpansionMode(e3.target.value),
|
|
113945
113977
|
className: "text-xs px-2 py-1 bg-white border border-gray-300 rounded focus:outline-none focus:ring-1 focus:ring-blue-500",
|
|
113946
113978
|
title: "Control auto-expansion behavior during live updates",
|
|
113947
|
-
"data-id": "debug_panel_expansion_controls_live_mode_select",
|
|
113979
|
+
"data-test-id": "debug_panel_expansion_controls_live_mode_select",
|
|
113948
113980
|
children: [
|
|
113949
113981
|
/* @__PURE__ */ jsxRuntimeExports.jsx("option", { value: "all", children: "Expand All" }),
|
|
113950
113982
|
/* @__PURE__ */ jsxRuntimeExports.jsx("option", { value: "last", children: "Expand Last" }),
|
|
@@ -113954,18 +113986,18 @@ const DebugPanel = forwardRef(({
|
|
|
113954
113986
|
)
|
|
113955
113987
|
] })
|
|
113956
113988
|
] }),
|
|
113957
|
-
sessionTree.runs.map((run2) => /* @__PURE__ */ jsxRuntimeExports.jsxs("div", { className: "flex flex-col gap-1", "data-id": `debug_panel_run_${run2.runId}`, children: [
|
|
113958
|
-
/* @__PURE__ */ jsxRuntimeExports.jsxs("div", { className: "rounded-[8px] border border-gray-300 bg-white overflow-hidden", "data-id": `debug_panel_run_container_${run2.runId}`, children: [
|
|
113959
|
-
/* @__PURE__ */ jsxRuntimeExports.jsx("div", { className: "flex flex-col w-full", "data-id": `debug_panel_run_header_${run2.runId}`, children: /* @__PURE__ */ jsxRuntimeExports.jsxs("div", { className: "flex items-center gap-2 p-[8px] bg-gray-50", "data-id": `debug_panel_run_header_content_${run2.runId}`, children: [
|
|
113960
|
-
/* @__PURE__ */ jsxRuntimeExports.jsx("svg", { width: "16", height: "16", viewBox: "0 0 16 16", fill: "none", className: "flex-shrink-0", "data-id": `debug_panel_run_header_icon_${run2.runId}`, children: /* @__PURE__ */ jsxRuntimeExports.jsx("path", { "fill-rule": "evenodd", "clip-rule": "evenodd", d: "M10.8277 1.33398C11.3643 1.33398 11.8072 1.33396 12.168 1.36343C12.5428 1.39405 12.8872 1.45978 13.2108 1.62463C13.7125 1.8803 14.1205 2.28825 14.3762 2.79001C14.541 3.11356 14.6067 3.45803 14.6374 3.83276C14.6668 4.19356 14.6668 4.63646 14.6668 5.1731V9.0235C14.6668 9.47003 14.6668 9.83861 14.6462 10.1404C14.6249 10.4532 14.5792 10.7426 14.4638 11.0211C14.1932 11.6746 13.674 12.1937 13.0206 12.4643C12.7421 12.5797 12.4527 12.6254 12.1399 12.6467C11.8381 12.6673 11.4695 12.6673 11.023 12.6673H11.0002C10.6424 12.6673 10.5714 12.6715 10.5136 12.6852C10.4129 12.7089 10.3191 12.7558 10.2397 12.8221C10.1941 12.8602 10.1481 12.9145 9.9335 13.2007L8.94888 14.5135C8.88665 14.5965 8.81628 14.6904 8.74857 14.7657C8.6739 14.8487 8.54979 14.971 8.36264 15.0438C8.1295 15.1344 7.87083 15.1344 7.6377 15.0438C7.45054 14.971 7.32641 14.8487 7.25174 14.7657C7.18403 14.6904 7.11368 14.5965 7.05145 14.5135L6.06683 13.2007C5.85221 12.9145 5.80624 12.8602 5.76065 12.8221C5.68119 12.7558 5.58739 12.7089 5.48666 12.6852C5.42887 12.6715 5.35786 12.6673 5.00015 12.6673H4.9773C4.53078 12.6673 4.16221 12.6673 3.86047 12.6467C3.54762 12.6254 3.25822 12.5797 2.97968 12.4643C2.32627 12.1937 1.80712 11.6746 1.53647 11.0211C1.42109 10.7426 1.37541 10.4532 1.35407 10.1404C1.33348 9.83861 1.33349 9.47003 1.3335 9.0235V5.17313C1.33349 4.63648 1.33347 4.19356 1.36295 3.83276C1.39356 3.45803 1.45929 3.11356 1.62415 2.79001C1.87981 2.28825 2.28776 1.8803 2.78952 1.62463C3.11308 1.45978 3.45755 1.39405 3.83228 1.36343C4.19307 1.33396 4.63599 1.33398 5.17264 1.33398H10.8277ZM10.4715 4.52924C10.2112 4.2689 9.78906 4.26889 9.52872 4.52924L6.66681 7.39114V5.6673C6.6668 5.29912 6.36834 5.00064 6.00015 5.00064C5.63197 5.00064 5.33351 5.29912 5.3335 5.6673V9.00064C5.3335 9.17745 5.40373 9.34702 5.52875 9.47205C5.65377 9.59707 5.82334 9.6673 6.00015 9.6673H9.3335L9.35068 9.66708C9.71092 9.65796 10.0002 9.36308 10.0002 9.00064C10.0001 8.63821 9.71092 8.34332 9.35068 8.3342L9.3335 8.33398H7.60962L10.4715 5.47205C10.7319 5.2117 10.7319 4.78958 10.4715 4.52924Z", fill: "#079455" }) }),
|
|
113989
|
+
sessionTree.runs.map((run2) => /* @__PURE__ */ jsxRuntimeExports.jsxs("div", { className: "flex flex-col gap-1", "data-test-id": `debug_panel_run_${run2.runId}`, children: [
|
|
113990
|
+
/* @__PURE__ */ jsxRuntimeExports.jsxs("div", { className: "rounded-[8px] border border-gray-300 bg-white overflow-hidden", "data-test-id": `debug_panel_run_container_${run2.runId}`, children: [
|
|
113991
|
+
/* @__PURE__ */ jsxRuntimeExports.jsx("div", { className: "flex flex-col w-full", "data-test-id": `debug_panel_run_header_${run2.runId}`, children: /* @__PURE__ */ jsxRuntimeExports.jsxs("div", { className: "flex items-center gap-2 p-[8px] bg-gray-50", "data-test-id": `debug_panel_run_header_content_${run2.runId}`, children: [
|
|
113992
|
+
/* @__PURE__ */ jsxRuntimeExports.jsx("svg", { width: "16", height: "16", viewBox: "0 0 16 16", fill: "none", className: "flex-shrink-0", "data-test-id": `debug_panel_run_header_icon_${run2.runId}`, children: /* @__PURE__ */ jsxRuntimeExports.jsx("path", { "fill-rule": "evenodd", "clip-rule": "evenodd", d: "M10.8277 1.33398C11.3643 1.33398 11.8072 1.33396 12.168 1.36343C12.5428 1.39405 12.8872 1.45978 13.2108 1.62463C13.7125 1.8803 14.1205 2.28825 14.3762 2.79001C14.541 3.11356 14.6067 3.45803 14.6374 3.83276C14.6668 4.19356 14.6668 4.63646 14.6668 5.1731V9.0235C14.6668 9.47003 14.6668 9.83861 14.6462 10.1404C14.6249 10.4532 14.5792 10.7426 14.4638 11.0211C14.1932 11.6746 13.674 12.1937 13.0206 12.4643C12.7421 12.5797 12.4527 12.6254 12.1399 12.6467C11.8381 12.6673 11.4695 12.6673 11.023 12.6673H11.0002C10.6424 12.6673 10.5714 12.6715 10.5136 12.6852C10.4129 12.7089 10.3191 12.7558 10.2397 12.8221C10.1941 12.8602 10.1481 12.9145 9.9335 13.2007L8.94888 14.5135C8.88665 14.5965 8.81628 14.6904 8.74857 14.7657C8.6739 14.8487 8.54979 14.971 8.36264 15.0438C8.1295 15.1344 7.87083 15.1344 7.6377 15.0438C7.45054 14.971 7.32641 14.8487 7.25174 14.7657C7.18403 14.6904 7.11368 14.5965 7.05145 14.5135L6.06683 13.2007C5.85221 12.9145 5.80624 12.8602 5.76065 12.8221C5.68119 12.7558 5.58739 12.7089 5.48666 12.6852C5.42887 12.6715 5.35786 12.6673 5.00015 12.6673H4.9773C4.53078 12.6673 4.16221 12.6673 3.86047 12.6467C3.54762 12.6254 3.25822 12.5797 2.97968 12.4643C2.32627 12.1937 1.80712 11.6746 1.53647 11.0211C1.42109 10.7426 1.37541 10.4532 1.35407 10.1404C1.33348 9.83861 1.33349 9.47003 1.3335 9.0235V5.17313C1.33349 4.63648 1.33347 4.19356 1.36295 3.83276C1.39356 3.45803 1.45929 3.11356 1.62415 2.79001C1.87981 2.28825 2.28776 1.8803 2.78952 1.62463C3.11308 1.45978 3.45755 1.39405 3.83228 1.36343C4.19307 1.33396 4.63599 1.33398 5.17264 1.33398H10.8277ZM10.4715 4.52924C10.2112 4.2689 9.78906 4.26889 9.52872 4.52924L6.66681 7.39114V5.6673C6.6668 5.29912 6.36834 5.00064 6.00015 5.00064C5.63197 5.00064 5.33351 5.29912 5.3335 5.6673V9.00064C5.3335 9.17745 5.40373 9.34702 5.52875 9.47205C5.65377 9.59707 5.82334 9.6673 6.00015 9.6673H9.3335L9.35068 9.66708C9.71092 9.65796 10.0002 9.36308 10.0002 9.00064C10.0001 8.63821 9.71092 8.34332 9.35068 8.3342L9.3335 8.33398H7.60962L10.4715 5.47205C10.7319 5.2117 10.7319 4.78958 10.4715 4.52924Z", fill: "#079455" }) }),
|
|
113961
113993
|
/* @__PURE__ */ jsxRuntimeExports.jsx(
|
|
113962
113994
|
"div",
|
|
113963
113995
|
{
|
|
113964
113996
|
className: "flex-1 cursor-pointer select-none truncate",
|
|
113965
113997
|
onClick: () => handleRunToggle(run2.runId),
|
|
113966
113998
|
title: run2.userInput,
|
|
113967
|
-
"data-id": `debug_panel_run_title_${run2.runId}`,
|
|
113968
|
-
children: /* @__PURE__ */ jsxRuntimeExports.jsx("span", { className: "text-xs text-gray-900 truncate", "data-id": `debug_panel_run_title_text_${run2.runId}`, children: run2.userInput || `Run ${run2.runId}` })
|
|
113999
|
+
"data-test-id": `debug_panel_run_title_${run2.runId}`,
|
|
114000
|
+
children: /* @__PURE__ */ jsxRuntimeExports.jsx("span", { className: "text-xs text-gray-900 truncate", "data-test-id": `debug_panel_run_title_text_${run2.runId}`, children: run2.userInput || `Run ${run2.runId}` })
|
|
113969
114001
|
}
|
|
113970
114002
|
),
|
|
113971
114003
|
/* @__PURE__ */ jsxRuntimeExports.jsx(
|
|
@@ -113986,7 +114018,7 @@ const DebugPanel = forwardRef(({
|
|
|
113986
114018
|
const anyDetailsVisible = Array.from(runNodeIds).some((nodeId) => selectedNodeIds.has(nodeId));
|
|
113987
114019
|
return anyDetailsVisible ? "Hide all node details in this run" : "Show all node details in this run";
|
|
113988
114020
|
})(),
|
|
113989
|
-
"data-id": `debug_panel_run_details_toggle_${run2.runId}`,
|
|
114021
|
+
"data-test-id": `debug_panel_run_details_toggle_${run2.runId}`,
|
|
113990
114022
|
children: (() => {
|
|
113991
114023
|
const runNodeIds = /* @__PURE__ */ new Set();
|
|
113992
114024
|
const collectNodeIds = (node) => {
|
|
@@ -114014,14 +114046,14 @@ const DebugPanel = forwardRef(({
|
|
|
114014
114046
|
},
|
|
114015
114047
|
className: "p-1 hover:bg-gray-200 rounded transition-colors flex-shrink-0",
|
|
114016
114048
|
title: expandedRuns.has(run2.runId) ? "Collapse run" : "Expand run",
|
|
114017
|
-
"data-id": `debug_panel_run_toggle_${run2.runId}`,
|
|
114049
|
+
"data-test-id": `debug_panel_run_toggle_${run2.runId}`,
|
|
114018
114050
|
children: /* @__PURE__ */ jsxRuntimeExports.jsx(ChevronDown, { className: `w-[16px] h-[16px] text-gray-400 transition-transform ${expandedRuns.has(run2.runId) ? "rotate-180" : ""}` })
|
|
114019
114051
|
}
|
|
114020
114052
|
)
|
|
114021
114053
|
] }) }),
|
|
114022
|
-
expandedRuns.has(run2.runId) && /* @__PURE__ */ jsxRuntimeExports.jsx("div", { className: "bg-white w-full flex flex-col", "data-id": `debug_panel_run_execution_trees_${run2.runId}`, children: run2.rootNodes && run2.rootNodes.map((rootNode, index) => {
|
|
114054
|
+
expandedRuns.has(run2.runId) && /* @__PURE__ */ jsxRuntimeExports.jsx("div", { className: "bg-white w-full flex flex-col", "data-test-id": `debug_panel_run_execution_trees_${run2.runId}`, children: run2.rootNodes && run2.rootNodes.map((rootNode, index) => {
|
|
114023
114055
|
var _a;
|
|
114024
|
-
return /* @__PURE__ */ jsxRuntimeExports.jsx("div", { className: "w-full", "data-id": `debug_panel_run_root_node_${run2.runId}_${index}`, children: /* @__PURE__ */ jsxRuntimeExports.jsx(
|
|
114056
|
+
return /* @__PURE__ */ jsxRuntimeExports.jsx("div", { className: "w-full", "data-test-id": `debug_panel_run_root_node_${run2.runId}_${index}`, children: /* @__PURE__ */ jsxRuntimeExports.jsx(
|
|
114025
114057
|
DebugCard,
|
|
114026
114058
|
{
|
|
114027
114059
|
node: updateTreeExpansion(rootNode),
|
|
@@ -114107,22 +114139,22 @@ const DebugPanel = forwardRef(({
|
|
|
114107
114139
|
};
|
|
114108
114140
|
const outputFromNodes = run2.rootNodes ? findFinalOutput(run2.rootNodes) : void 0;
|
|
114109
114141
|
const finalOutput = outputFromNodes || run2.finalOutput;
|
|
114110
|
-
return finalOutput ? /* @__PURE__ */ jsxRuntimeExports.jsxs("div", { className: "p-[8px] bg-gray-50 flex items-center gap-[8px] w-full border-t border-gray-200", "data-id": `debug_panel_run_final_output_${run2.runId}`, children: [
|
|
114111
|
-
/* @__PURE__ */ jsxRuntimeExports.jsx("svg", { width: "16", height: "16", viewBox: "0 0 16 16", fill: "none", className: "flex-shrink-0", "data-id": `debug_panel_run_final_output_icon_${run2.runId}`, children: /* @__PURE__ */ jsxRuntimeExports.jsx("path", { "fill-rule": "evenodd", "clip-rule": "evenodd", d: "M10.8277 1.33398C11.3643 1.33398 11.8072 1.33396 12.168 1.36343C12.5428 1.39405 12.8872 1.45978 13.2108 1.62463C13.7125 1.8803 14.1205 2.28825 14.3762 2.79001C14.541 3.11356 14.6067 3.45803 14.6374 3.83276C14.6668 4.19356 14.6668 4.63646 14.6668 5.1731V9.0235C14.6668 9.47003 14.6668 9.83861 14.6462 10.1404C14.6249 10.4532 14.5792 10.7426 14.4638 11.0211C14.1932 11.6746 13.674 12.1937 13.0206 12.4643C12.7421 12.5797 12.4527 12.6254 12.1399 12.6467C11.8381 12.6673 11.4695 12.6673 11.023 12.6673H11.0002C10.6424 12.6673 10.5714 12.6715 10.5136 12.6852C10.4129 12.7089 10.3191 12.7558 10.2397 12.8221C10.1941 12.8602 10.1481 12.9145 9.9335 13.2007L8.94888 14.5135C8.88665 14.5965 8.81628 14.6904 8.74857 14.7657C8.6739 14.8487 8.54979 14.971 8.36264 15.0438C8.1295 15.1344 7.87083 15.1344 7.6377 15.0438C7.45054 14.971 7.32641 14.8487 7.25174 14.7657C7.18403 14.6904 7.11368 14.5965 7.05145 14.5135L6.06683 13.2007C5.85221 12.9145 5.80624 12.8602 5.76065 12.8221C5.68119 12.7558 5.58739 12.7089 5.48666 12.6852C5.42887 12.6715 5.35786 12.6673 5.00015 12.6673H4.9773C4.53078 12.6673 4.16221 12.6673 3.86047 12.6467C3.54762 12.6254 3.25822 12.5797 2.97968 12.4643C2.32627 12.1937 1.80712 11.6746 1.53647 11.0211C1.42109 10.7426 1.37541 10.4532 1.35407 10.1404C1.33348 9.83861 1.33349 9.47003 1.3335 9.0235V5.17313C1.33349 4.63648 1.33347 4.19356 1.36295 3.83276C1.39356 3.45803 1.45929 3.11356 1.62415 2.79001C1.87981 2.28825 2.28776 1.8803 2.78952 1.62463C3.11308 1.45978 3.45755 1.39405 3.83228 1.36343C4.19307 1.33396 4.63599 1.33398 5.17264 1.33398H10.8277ZM6.66653 4.33398C6.29835 4.334 5.99988 4.63246 5.99988 5.00064C5.99988 5.36882 6.29835 5.66729 6.66653 5.6673H8.39041L5.52847 8.52924C5.26813 8.78958 5.26813 9.2117 5.52847 9.47205C5.78882 9.73239 6.21093 9.73239 6.47128 9.47205L9.33322 6.61011V8.33398C9.33323 8.70217 9.6317 9.00064 9.99988 9.00064C10.3681 9.00064 10.6665 8.70217 10.6665 8.33398V5.00064C10.6665 4.63821 10.3773 4.34333 10.0171 4.3342L9.99988 4.33398H6.66653Z", fill: "#155EEF" }) }),
|
|
114112
|
-
/* @__PURE__ */ jsxRuntimeExports.jsx("span", { className: "flex-1 text-xs text-gray-900 truncate", title: convertToString(finalOutput), "data-id": `debug_panel_run_final_output_text_${run2.runId}`, children: convertToString(finalOutput) }),
|
|
114113
|
-
/* @__PURE__ */ jsxRuntimeExports.jsxs("div", { className: "flex items-center gap-[8px] flex-shrink-0", "data-id": `debug_panel_run_final_output_metadata_${run2.runId}`, children: [
|
|
114114
|
-
run2.duration && /* @__PURE__ */ jsxRuntimeExports.jsxs("div", { className: "flex items-center gap-[4px]", "data-id": `debug_panel_run_final_output_duration_${run2.runId}`, children: [
|
|
114142
|
+
return finalOutput ? /* @__PURE__ */ jsxRuntimeExports.jsxs("div", { className: "p-[8px] bg-gray-50 flex items-center gap-[8px] w-full border-t border-gray-200", "data-test-id": `debug_panel_run_final_output_${run2.runId}`, children: [
|
|
114143
|
+
/* @__PURE__ */ jsxRuntimeExports.jsx("svg", { width: "16", height: "16", viewBox: "0 0 16 16", fill: "none", className: "flex-shrink-0", "data-test-id": `debug_panel_run_final_output_icon_${run2.runId}`, children: /* @__PURE__ */ jsxRuntimeExports.jsx("path", { "fill-rule": "evenodd", "clip-rule": "evenodd", d: "M10.8277 1.33398C11.3643 1.33398 11.8072 1.33396 12.168 1.36343C12.5428 1.39405 12.8872 1.45978 13.2108 1.62463C13.7125 1.8803 14.1205 2.28825 14.3762 2.79001C14.541 3.11356 14.6067 3.45803 14.6374 3.83276C14.6668 4.19356 14.6668 4.63646 14.6668 5.1731V9.0235C14.6668 9.47003 14.6668 9.83861 14.6462 10.1404C14.6249 10.4532 14.5792 10.7426 14.4638 11.0211C14.1932 11.6746 13.674 12.1937 13.0206 12.4643C12.7421 12.5797 12.4527 12.6254 12.1399 12.6467C11.8381 12.6673 11.4695 12.6673 11.023 12.6673H11.0002C10.6424 12.6673 10.5714 12.6715 10.5136 12.6852C10.4129 12.7089 10.3191 12.7558 10.2397 12.8221C10.1941 12.8602 10.1481 12.9145 9.9335 13.2007L8.94888 14.5135C8.88665 14.5965 8.81628 14.6904 8.74857 14.7657C8.6739 14.8487 8.54979 14.971 8.36264 15.0438C8.1295 15.1344 7.87083 15.1344 7.6377 15.0438C7.45054 14.971 7.32641 14.8487 7.25174 14.7657C7.18403 14.6904 7.11368 14.5965 7.05145 14.5135L6.06683 13.2007C5.85221 12.9145 5.80624 12.8602 5.76065 12.8221C5.68119 12.7558 5.58739 12.7089 5.48666 12.6852C5.42887 12.6715 5.35786 12.6673 5.00015 12.6673H4.9773C4.53078 12.6673 4.16221 12.6673 3.86047 12.6467C3.54762 12.6254 3.25822 12.5797 2.97968 12.4643C2.32627 12.1937 1.80712 11.6746 1.53647 11.0211C1.42109 10.7426 1.37541 10.4532 1.35407 10.1404C1.33348 9.83861 1.33349 9.47003 1.3335 9.0235V5.17313C1.33349 4.63648 1.33347 4.19356 1.36295 3.83276C1.39356 3.45803 1.45929 3.11356 1.62415 2.79001C1.87981 2.28825 2.28776 1.8803 2.78952 1.62463C3.11308 1.45978 3.45755 1.39405 3.83228 1.36343C4.19307 1.33396 4.63599 1.33398 5.17264 1.33398H10.8277ZM6.66653 4.33398C6.29835 4.334 5.99988 4.63246 5.99988 5.00064C5.99988 5.36882 6.29835 5.66729 6.66653 5.6673H8.39041L5.52847 8.52924C5.26813 8.78958 5.26813 9.2117 5.52847 9.47205C5.78882 9.73239 6.21093 9.73239 6.47128 9.47205L9.33322 6.61011V8.33398C9.33323 8.70217 9.6317 9.00064 9.99988 9.00064C10.3681 9.00064 10.6665 8.70217 10.6665 8.33398V5.00064C10.6665 4.63821 10.3773 4.34333 10.0171 4.3342L9.99988 4.33398H6.66653Z", fill: "#155EEF" }) }),
|
|
114144
|
+
/* @__PURE__ */ jsxRuntimeExports.jsx("span", { className: "flex-1 text-xs text-gray-900 truncate", title: convertToString(finalOutput), "data-test-id": `debug_panel_run_final_output_text_${run2.runId}`, children: convertToString(finalOutput) }),
|
|
114145
|
+
/* @__PURE__ */ jsxRuntimeExports.jsxs("div", { className: "flex items-center gap-[8px] flex-shrink-0", "data-test-id": `debug_panel_run_final_output_metadata_${run2.runId}`, children: [
|
|
114146
|
+
run2.duration && /* @__PURE__ */ jsxRuntimeExports.jsxs("div", { className: "flex items-center gap-[4px]", "data-test-id": `debug_panel_run_final_output_duration_${run2.runId}`, children: [
|
|
114115
114147
|
/* @__PURE__ */ jsxRuntimeExports.jsx(Clock, { className: "w-[12px] h-[12px] text-gray-400" }),
|
|
114116
114148
|
/* @__PURE__ */ jsxRuntimeExports.jsx("span", { className: "text-[10px] text-gray-500 whitespace-nowrap", children: formatDuration(run2.duration) })
|
|
114117
114149
|
] }),
|
|
114118
|
-
run2.totalTokens && /* @__PURE__ */ jsxRuntimeExports.jsx("span", { className: "text-[10px] text-gray-500 whitespace-nowrap", "data-id": `debug_panel_run_final_output_tokens_${run2.runId}`, children: formatTokens(run2.totalTokens) })
|
|
114150
|
+
run2.totalTokens && /* @__PURE__ */ jsxRuntimeExports.jsx("span", { className: "text-[10px] text-gray-500 whitespace-nowrap", "data-test-id": `debug_panel_run_final_output_tokens_${run2.runId}`, children: formatTokens(run2.totalTokens) })
|
|
114119
114151
|
] })
|
|
114120
114152
|
] }) : null;
|
|
114121
114153
|
})()
|
|
114122
114154
|
] }),
|
|
114123
|
-
/* @__PURE__ */ jsxRuntimeExports.jsxs("div", { className: "flex items-center justify-end gap-2 py-1", "data-id": `debug_panel_run_footer_${run2.runId}`, children: [
|
|
114124
|
-
/* @__PURE__ */ jsxRuntimeExports.jsx("span", { className: "text-xs text-gray-400", "data-id": `debug_panel_run_footer_id_${run2.runId}`, children: run2.runId }),
|
|
114125
|
-
/* @__PURE__ */ jsxRuntimeExports.jsxs("div", { className: "flex items-center gap-2", "data-id": `debug_panel_run_footer_actions_${run2.runId}`, children: [
|
|
114155
|
+
/* @__PURE__ */ jsxRuntimeExports.jsxs("div", { className: "flex items-center justify-end gap-2 py-1", "data-test-id": `debug_panel_run_footer_${run2.runId}`, children: [
|
|
114156
|
+
/* @__PURE__ */ jsxRuntimeExports.jsx("span", { className: "text-xs text-gray-400", "data-test-id": `debug_panel_run_footer_id_${run2.runId}`, children: run2.runId }),
|
|
114157
|
+
/* @__PURE__ */ jsxRuntimeExports.jsxs("div", { className: "flex items-center gap-2", "data-test-id": `debug_panel_run_footer_actions_${run2.runId}`, children: [
|
|
114126
114158
|
/* @__PURE__ */ jsxRuntimeExports.jsx(
|
|
114127
114159
|
CopyButton$1,
|
|
114128
114160
|
{
|
|
@@ -114148,7 +114180,7 @@ const DebugPanel = forwardRef(({
|
|
|
114148
114180
|
}
|
|
114149
114181
|
}
|
|
114150
114182
|
},
|
|
114151
|
-
"data-id": `debug_panel_run_footer_external_link_${run2.runId}`,
|
|
114183
|
+
"data-test-id": `debug_panel_run_footer_external_link_${run2.runId}`,
|
|
114152
114184
|
children: /* @__PURE__ */ jsxRuntimeExports.jsx(ExternalLink, { className: "w-3 h-3 text-gray-400" })
|
|
114153
114185
|
}
|
|
114154
114186
|
)
|
|
@@ -141001,7 +141033,7 @@ const VariableChipComponent = ({
|
|
|
141001
141033
|
backgroundColor: config2.bgColor,
|
|
141002
141034
|
borderColor: config2.borderColor
|
|
141003
141035
|
},
|
|
141004
|
-
"data-id": `md-editor-variable-${variableType}-${path}`,
|
|
141036
|
+
"data-test-id": `md-editor-variable-${variableType}-${path}`,
|
|
141005
141037
|
"data-variable-type": variableType,
|
|
141006
141038
|
"data-path": path,
|
|
141007
141039
|
title: displayName || fullSyntax,
|
|
@@ -141226,7 +141258,7 @@ const MentionChipComponent = ({
|
|
|
141226
141258
|
backgroundColor: config2.bgColor,
|
|
141227
141259
|
color: config2.color
|
|
141228
141260
|
},
|
|
141229
|
-
"data-id": `md-editor-mention-${mentionType}-${name.toLowerCase().replace(/\s+/g, "-")}`,
|
|
141261
|
+
"data-test-id": `md-editor-mention-${mentionType}-${name.toLowerCase().replace(/\s+/g, "-")}`,
|
|
141230
141262
|
"data-mention-type": mentionType,
|
|
141231
141263
|
"data-name": name,
|
|
141232
141264
|
title: name,
|
|
@@ -141297,9 +141329,9 @@ const MentionChipExtension = Node$1.create({
|
|
|
141297
141329
|
},
|
|
141298
141330
|
id: {
|
|
141299
141331
|
default: "",
|
|
141300
|
-
parseHTML: (element) => element.getAttribute("data-id"),
|
|
141332
|
+
parseHTML: (element) => element.getAttribute("data-test-id"),
|
|
141301
141333
|
renderHTML: (attributes) => ({
|
|
141302
|
-
"data-id": attributes["id"]
|
|
141334
|
+
"data-test-id": attributes["id"]
|
|
141303
141335
|
})
|
|
141304
141336
|
},
|
|
141305
141337
|
name: {
|
|
@@ -142109,7 +142141,7 @@ const SlashMenu = forwardRef(
|
|
|
142109
142141
|
{
|
|
142110
142142
|
ref: menuRef,
|
|
142111
142143
|
className: "k-md-editor-slash-menu w-[300px] max-h-[360px] bg-white rounded-lg shadow-lg overflow-hidden flex flex-col",
|
|
142112
|
-
"data-id": "md-editor-slash-menu",
|
|
142144
|
+
"data-test-id": "md-editor-slash-menu",
|
|
142113
142145
|
children: [
|
|
142114
142146
|
hasBlockItems && /* @__PURE__ */ jsxRuntimeExports.jsxs(jsxRuntimeExports.Fragment, { children: [
|
|
142115
142147
|
/* @__PURE__ */ jsxRuntimeExports.jsx("div", { className: "px-2 pt-2 pb-1", children: /* @__PURE__ */ jsxRuntimeExports.jsx("span", { className: "text-[11px] font-semibold text-gray-400 uppercase tracking-wide pl-1", children: "Blocks" }) }),
|
|
@@ -142131,7 +142163,7 @@ const SlashMenu = forwardRef(
|
|
|
142131
142163
|
title: `${item.label}${item.shortcut ? ` (${item.shortcut})` : ""}`,
|
|
142132
142164
|
className: `flex items-center justify-center w-9 h-9 p-0 border-0 rounded-lg cursor-pointer transition-all duration-150 shrink-0 ${isSelected ? "bg-gray-200 text-gray-800" : "bg-gray-50 text-gray-500 hover:bg-gray-200 hover:text-gray-800"}`,
|
|
142133
142165
|
onMouseEnter: () => setSelectedIndex(index),
|
|
142134
|
-
"data-id": `md-editor-slash-block-${item.id}`,
|
|
142166
|
+
"data-test-id": `md-editor-slash-block-${item.id}`,
|
|
142135
142167
|
children: item.icon
|
|
142136
142168
|
},
|
|
142137
142169
|
item.id
|
|
@@ -142150,7 +142182,7 @@ const SlashMenu = forwardRef(
|
|
|
142150
142182
|
onClick: handleBack,
|
|
142151
142183
|
className: "flex items-center justify-center w-6 h-6 p-0 border-0 bg-gray-100 rounded cursor-pointer text-gray-500 hover:bg-gray-200",
|
|
142152
142184
|
"aria-label": "Go back",
|
|
142153
|
-
"data-id": "md-editor-slash-back-btn",
|
|
142185
|
+
"data-test-id": "md-editor-slash-back-btn",
|
|
142154
142186
|
children: /* @__PURE__ */ jsxRuntimeExports.jsx(ChevronLeft, { size: 16 })
|
|
142155
142187
|
}
|
|
142156
142188
|
),
|
|
@@ -142170,7 +142202,7 @@ const SlashMenu = forwardRef(
|
|
|
142170
142202
|
},
|
|
142171
142203
|
placeholder: "Search...",
|
|
142172
142204
|
className: "flex-1 bg-transparent text-sm border-0 outline-none text-gray-700 placeholder:text-gray-400",
|
|
142173
|
-
"data-id": "md-editor-slash-search"
|
|
142205
|
+
"data-test-id": "md-editor-slash-search"
|
|
142174
142206
|
}
|
|
142175
142207
|
)
|
|
142176
142208
|
] }) })
|
|
@@ -142205,7 +142237,7 @@ const SlashMenu = forwardRef(
|
|
|
142205
142237
|
title: isDisabled ? disabledReason : void 0,
|
|
142206
142238
|
className: `flex items-center gap-2.5 w-full py-2 px-2.5 border-0 rounded-md text-left transition-colors duration-100 ${isDisabled ? "cursor-not-allowed opacity-50" : "cursor-pointer"} ${isSelected && !isDisabled ? "bg-gray-100" : "bg-transparent hover:bg-gray-100"}`,
|
|
142207
142239
|
onMouseEnter: () => !isDisabled && setSelectedIndex(adjustedIndex),
|
|
142208
|
-
"data-id": `md-editor-slash-item-${"id" in item ? item.id : label.toLowerCase().replace(/\s+/g, "-")}`,
|
|
142240
|
+
"data-test-id": `md-editor-slash-item-${"id" in item ? item.id : label.toLowerCase().replace(/\s+/g, "-")}`,
|
|
142209
142241
|
children: [
|
|
142210
142242
|
/* @__PURE__ */ jsxRuntimeExports.jsx("span", { className: `flex items-center justify-center w-7 h-7 rounded-md bg-gray-100 shrink-0 ${isDisabled ? "text-gray-300" : "text-gray-500"}`, children: getIcon(item) }),
|
|
142211
142243
|
/* @__PURE__ */ jsxRuntimeExports.jsx("div", { className: "flex-1 min-w-0", children: /* @__PURE__ */ jsxRuntimeExports.jsx("div", { className: `text-[13px] font-medium truncate ${isDisabled ? "text-gray-400" : "text-gray-800"}`, children: label }) }),
|
|
@@ -142849,7 +142881,7 @@ const VariableMenu = ({
|
|
|
142849
142881
|
ref: menuRef,
|
|
142850
142882
|
className: "k-md-editor-variable-menu fixed w-[280px] max-h-[320px] bg-white rounded-lg shadow-lg z-[9999] overflow-hidden flex flex-col",
|
|
142851
142883
|
style: { top: adjustedPosition.top, left: adjustedPosition.left },
|
|
142852
|
-
"data-id": "md-editor-variable-menu",
|
|
142884
|
+
"data-test-id": "md-editor-variable-menu",
|
|
142853
142885
|
children: [
|
|
142854
142886
|
/* @__PURE__ */ jsxRuntimeExports.jsxs("div", { className: "px-3 py-2 border-b border-gray-200 flex items-center gap-2", children: [
|
|
142855
142887
|
activeCategory && /* @__PURE__ */ jsxRuntimeExports.jsx(
|
|
@@ -142859,7 +142891,7 @@ const VariableMenu = ({
|
|
|
142859
142891
|
onClick: handleBack,
|
|
142860
142892
|
className: "flex items-center justify-center w-6 h-6 p-0 border-0 bg-gray-100 rounded cursor-pointer text-gray-500 hover:bg-gray-200",
|
|
142861
142893
|
"aria-label": "Go back",
|
|
142862
|
-
"data-id": "md-editor-variable-back-btn",
|
|
142894
|
+
"data-test-id": "md-editor-variable-back-btn",
|
|
142863
142895
|
children: /* @__PURE__ */ jsxRuntimeExports.jsx(ChevronLeft, { size: 16 })
|
|
142864
142896
|
}
|
|
142865
142897
|
),
|
|
@@ -142887,7 +142919,7 @@ const VariableMenu = ({
|
|
|
142887
142919
|
},
|
|
142888
142920
|
placeholder: "memory.store.field",
|
|
142889
142921
|
className: "flex-1 border border-blue-300 bg-white rounded px-2 py-1.5 outline-none text-[13px] text-gray-700 font-mono focus:border-blue-500 focus:ring-1 focus:ring-blue-500",
|
|
142890
|
-
"data-id": "md-editor-custom-variable-input"
|
|
142922
|
+
"data-test-id": "md-editor-custom-variable-input"
|
|
142891
142923
|
}
|
|
142892
142924
|
),
|
|
142893
142925
|
/* @__PURE__ */ jsxRuntimeExports.jsx("span", { className: "text-[14px] font-mono text-gray-500", children: "}}" })
|
|
@@ -142925,7 +142957,7 @@ const VariableMenu = ({
|
|
|
142925
142957
|
onChange: (e3) => onQueryChange(e3.target.value),
|
|
142926
142958
|
placeholder: "Search...",
|
|
142927
142959
|
className: "flex-1 border-0 bg-transparent outline-none text-[13px] text-gray-700",
|
|
142928
|
-
"data-id": "md-editor-variable-search"
|
|
142960
|
+
"data-test-id": "md-editor-variable-search"
|
|
142929
142961
|
}
|
|
142930
142962
|
)
|
|
142931
142963
|
] }) }),
|
|
@@ -142947,7 +142979,7 @@ const VariableMenu = ({
|
|
|
142947
142979
|
onClick: () => handleItemClick(item),
|
|
142948
142980
|
className: `flex items-center gap-2.5 w-full py-2 px-2.5 border-0 rounded-md text-left cursor-pointer transition-colors duration-100 ${index === selectedIndex ? "bg-gray-100" : "bg-transparent hover:bg-gray-100"}`,
|
|
142949
142981
|
onMouseEnter: () => setSelectedIndex(index),
|
|
142950
|
-
"data-id": `md-editor-variable-item-${isCategory ? item.id : item.id}`,
|
|
142982
|
+
"data-test-id": `md-editor-variable-item-${isCategory ? item.id : item.id}`,
|
|
142951
142983
|
children: [
|
|
142952
142984
|
/* @__PURE__ */ jsxRuntimeExports.jsx("span", { className: "flex items-center justify-center w-7 h-7 rounded-md bg-gray-100 text-gray-500 shrink-0", children: /* @__PURE__ */ jsxRuntimeExports.jsx(Icon, { size: 16 }) }),
|
|
142953
142985
|
/* @__PURE__ */ jsxRuntimeExports.jsxs("div", { className: "flex-1 min-w-0", children: [
|
|
@@ -142967,7 +142999,7 @@ const VariableMenu = ({
|
|
|
142967
142999
|
onClick: () => handleItemClick("custom"),
|
|
142968
143000
|
className: `flex items-center gap-2.5 w-full py-2 px-2.5 border-0 rounded-md text-left cursor-pointer transition-colors duration-100 border-t border-gray-100 mt-1 pt-2 ${selectedIndex === items.length ? "bg-blue-50" : "bg-transparent hover:bg-blue-50"}`,
|
|
142969
143001
|
onMouseEnter: () => setSelectedIndex(items.length),
|
|
142970
|
-
"data-id": "md-editor-variable-custom",
|
|
143002
|
+
"data-test-id": "md-editor-variable-custom",
|
|
142971
143003
|
children: [
|
|
142972
143004
|
/* @__PURE__ */ jsxRuntimeExports.jsx("span", { className: "flex items-center justify-center w-7 h-7 rounded-md bg-blue-100 text-blue-600 shrink-0", children: /* @__PURE__ */ jsxRuntimeExports.jsx(Plus, { size: 16 }) }),
|
|
142973
143005
|
/* @__PURE__ */ jsxRuntimeExports.jsxs("div", { className: "flex-1 min-w-0", children: [
|
|
@@ -143051,7 +143083,7 @@ const LinkEditor = ({ editor, initialUrl = "", onClose }) => {
|
|
|
143051
143083
|
"div",
|
|
143052
143084
|
{
|
|
143053
143085
|
className: "k-md-editor-link-editor flex items-center gap-1.5 p-1 bg-gray-800 rounded-lg shadow-lg min-w-[280px]",
|
|
143054
|
-
"data-id": "md-editor-link-editor",
|
|
143086
|
+
"data-test-id": "md-editor-link-editor",
|
|
143055
143087
|
onMouseDown: (e3) => e3.stopPropagation(),
|
|
143056
143088
|
children: [
|
|
143057
143089
|
/* @__PURE__ */ jsxRuntimeExports.jsxs("div", { className: "flex items-center flex-1 bg-gray-700 rounded-md px-2 gap-1.5", children: [
|
|
@@ -143066,7 +143098,7 @@ const LinkEditor = ({ editor, initialUrl = "", onClose }) => {
|
|
|
143066
143098
|
onKeyDown: handleKeyDown2,
|
|
143067
143099
|
placeholder: "Enter URL...",
|
|
143068
143100
|
className: "flex-1 h-8 bg-transparent border-none outline-none text-gray-100 text-[13px] font-inherit min-w-[150px]",
|
|
143069
|
-
"data-id": "md-editor-link-input"
|
|
143101
|
+
"data-test-id": "md-editor-link-input"
|
|
143070
143102
|
}
|
|
143071
143103
|
)
|
|
143072
143104
|
] }),
|
|
@@ -143077,7 +143109,7 @@ const LinkEditor = ({ editor, initialUrl = "", onClose }) => {
|
|
|
143077
143109
|
onClick: handleOpenLink,
|
|
143078
143110
|
title: "Open link",
|
|
143079
143111
|
className: "flex items-center justify-center w-7 h-7 p-0 border-0 rounded-md cursor-pointer bg-transparent text-gray-400 transition-all duration-150 hover:bg-gray-700 hover:text-blue-400",
|
|
143080
|
-
"data-id": "md-editor-link-open",
|
|
143112
|
+
"data-test-id": "md-editor-link-open",
|
|
143081
143113
|
children: /* @__PURE__ */ jsxRuntimeExports.jsx(ExternalLink, { size: 14 })
|
|
143082
143114
|
}
|
|
143083
143115
|
),
|
|
@@ -143088,7 +143120,7 @@ const LinkEditor = ({ editor, initialUrl = "", onClose }) => {
|
|
|
143088
143120
|
onClick: handleRemoveLink,
|
|
143089
143121
|
title: "Remove link",
|
|
143090
143122
|
className: "flex items-center justify-center w-7 h-7 p-0 border-0 rounded-md cursor-pointer bg-transparent text-gray-400 transition-all duration-150 hover:bg-gray-700 hover:text-red-500",
|
|
143091
|
-
"data-id": "md-editor-link-remove",
|
|
143123
|
+
"data-test-id": "md-editor-link-remove",
|
|
143092
143124
|
children: /* @__PURE__ */ jsxRuntimeExports.jsx(Link2Off, { size: 14 })
|
|
143093
143125
|
}
|
|
143094
143126
|
),
|
|
@@ -143099,7 +143131,7 @@ const LinkEditor = ({ editor, initialUrl = "", onClose }) => {
|
|
|
143099
143131
|
onClick: handleSubmit,
|
|
143100
143132
|
title: "Apply link",
|
|
143101
143133
|
className: "flex items-center justify-center w-7 h-7 p-0 border-0 rounded-md cursor-pointer bg-blue-500 text-white transition-all duration-150 hover:bg-blue-600",
|
|
143102
|
-
"data-id": "md-editor-link-apply",
|
|
143134
|
+
"data-test-id": "md-editor-link-apply",
|
|
143103
143135
|
children: /* @__PURE__ */ jsxRuntimeExports.jsx(Check, { size: 14 })
|
|
143104
143136
|
}
|
|
143105
143137
|
),
|
|
@@ -143110,7 +143142,7 @@ const LinkEditor = ({ editor, initialUrl = "", onClose }) => {
|
|
|
143110
143142
|
onClick: onClose,
|
|
143111
143143
|
title: "Cancel",
|
|
143112
143144
|
className: "flex items-center justify-center w-7 h-7 p-0 border-0 rounded-md cursor-pointer bg-transparent text-gray-400 transition-all duration-150 hover:bg-gray-700 hover:text-white",
|
|
143113
|
-
"data-id": "md-editor-link-cancel",
|
|
143145
|
+
"data-test-id": "md-editor-link-cancel",
|
|
143114
143146
|
children: /* @__PURE__ */ jsxRuntimeExports.jsx(X, { size: 14 })
|
|
143115
143147
|
}
|
|
143116
143148
|
)
|
|
@@ -143237,7 +143269,7 @@ const InlineToolbar = ({
|
|
|
143237
143269
|
"div",
|
|
143238
143270
|
{
|
|
143239
143271
|
className: "k-md-editor-inline-toolbar flex items-center gap-0.5 p-1 bg-gray-800 rounded-lg shadow-lg pointer-events-auto",
|
|
143240
|
-
"data-id": "md-editor-inline-toolbar",
|
|
143272
|
+
"data-test-id": "md-editor-inline-toolbar",
|
|
143241
143273
|
onMouseDown: (e3) => {
|
|
143242
143274
|
e3.stopPropagation();
|
|
143243
143275
|
},
|
|
@@ -143261,7 +143293,7 @@ const InlineToolbar = ({
|
|
|
143261
143293
|
title: `${item.label}${item.shortcut ? ` (${item.shortcut})` : ""}`,
|
|
143262
143294
|
"aria-label": item.label,
|
|
143263
143295
|
"aria-pressed": isActive2,
|
|
143264
|
-
"data-id": `md-editor-toolbar-${item.id}`,
|
|
143296
|
+
"data-test-id": `md-editor-toolbar-${item.id}`,
|
|
143265
143297
|
children: item.icon
|
|
143266
143298
|
}
|
|
143267
143299
|
),
|
|
@@ -143281,7 +143313,7 @@ const InlineToolbar = ({
|
|
|
143281
143313
|
className: `flex items-center justify-center w-8 h-8 p-0 border-0 rounded-md cursor-pointer transition-colors duration-150 pointer-events-auto ${isLinkActive ? "bg-gray-700 text-blue-400" : "bg-transparent text-gray-400 hover:bg-gray-700 hover:text-blue-400"}`,
|
|
143282
143314
|
"aria-label": "Link",
|
|
143283
143315
|
"aria-pressed": isLinkActive,
|
|
143284
|
-
"data-id": "md-editor-toolbar-link",
|
|
143316
|
+
"data-test-id": "md-editor-toolbar-link",
|
|
143285
143317
|
children: /* @__PURE__ */ jsxRuntimeExports.jsx(Link$1, { size: 16 })
|
|
143286
143318
|
}
|
|
143287
143319
|
),
|
|
@@ -143299,7 +143331,7 @@ const InlineToolbar = ({
|
|
|
143299
143331
|
title: "Refine with AI (⌘⇧R)",
|
|
143300
143332
|
className: "k-md-editor-inline-toolbar__ai-btn flex items-center justify-center gap-1 h-8 px-2.5 border-0 rounded-md cursor-pointer transition-colors duration-150 bg-transparent text-violet-400 text-xs font-medium pointer-events-auto hover:bg-violet-900 hover:text-white",
|
|
143301
143333
|
"aria-label": "Refine with AI",
|
|
143302
|
-
"data-id": "md-editor-toolbar-ai-refine",
|
|
143334
|
+
"data-test-id": "md-editor-toolbar-ai-refine",
|
|
143303
143335
|
children: [
|
|
143304
143336
|
/* @__PURE__ */ jsxRuntimeExports.jsx(Sparkles, { size: 14 }),
|
|
143305
143337
|
/* @__PURE__ */ jsxRuntimeExports.jsx("span", { children: "AI" })
|
|
@@ -143320,7 +143352,7 @@ const InlineToolbar = ({
|
|
|
143320
143352
|
title: "Delete selection",
|
|
143321
143353
|
className: "flex items-center justify-center w-8 h-8 p-0 border-0 rounded-md cursor-pointer transition-colors duration-150 bg-transparent text-gray-400 pointer-events-auto hover:bg-red-500/20 hover:text-red-400",
|
|
143322
143354
|
"aria-label": "Delete",
|
|
143323
|
-
"data-id": "md-editor-toolbar-delete",
|
|
143355
|
+
"data-test-id": "md-editor-toolbar-delete",
|
|
143324
143356
|
children: /* @__PURE__ */ jsxRuntimeExports.jsx(Trash2, { size: 16 })
|
|
143325
143357
|
}
|
|
143326
143358
|
)
|
|
@@ -143617,7 +143649,7 @@ const DragHandle = ({ editor }) => {
|
|
|
143617
143649
|
{
|
|
143618
143650
|
className: "k-md-editor-drag-handle-container absolute left-1 flex items-center gap-0.5 z-10 opacity-100 pointer-events-auto h-6 px-1.5 py-1 -ml-1 mt-0.5 rounded-md hover:bg-black/[0.03]",
|
|
143619
143651
|
style: { top: handleTop },
|
|
143620
|
-
"data-id": "md-editor-drag-handle",
|
|
143652
|
+
"data-test-id": "md-editor-drag-handle",
|
|
143621
143653
|
onMouseEnter: () => {
|
|
143622
143654
|
},
|
|
143623
143655
|
onMouseLeave: () => {
|
|
@@ -143637,7 +143669,7 @@ const DragHandle = ({ editor }) => {
|
|
|
143637
143669
|
className: "flex items-center justify-center w-[22px] h-[22px] p-0 border-0 rounded bg-transparent text-gray-400 cursor-pointer transition-all duration-150 hover:bg-black/[0.08] hover:text-gray-700",
|
|
143638
143670
|
onClick: handleAddClick,
|
|
143639
143671
|
title: "Add block below",
|
|
143640
|
-
"data-id": "md-editor-add-block-btn",
|
|
143672
|
+
"data-test-id": "md-editor-add-block-btn",
|
|
143641
143673
|
children: /* @__PURE__ */ jsxRuntimeExports.jsx(Plus, { size: 14 })
|
|
143642
143674
|
}
|
|
143643
143675
|
),
|
|
@@ -143648,7 +143680,7 @@ const DragHandle = ({ editor }) => {
|
|
|
143648
143680
|
draggable: "true",
|
|
143649
143681
|
onDragStart: handleDragStart,
|
|
143650
143682
|
title: "Drag to reorder",
|
|
143651
|
-
"data-id": "md-editor-drag-grip",
|
|
143683
|
+
"data-test-id": "md-editor-drag-grip",
|
|
143652
143684
|
children: /* @__PURE__ */ jsxRuntimeExports.jsx(GripVertical, { size: 14 })
|
|
143653
143685
|
}
|
|
143654
143686
|
)
|
|
@@ -143694,7 +143726,7 @@ const TableToolbar = ({ editor, theme = "light" }) => {
|
|
|
143694
143726
|
"div",
|
|
143695
143727
|
{
|
|
143696
143728
|
className: `inline-flex items-center gap-1.5 px-2 py-1.5 rounded-lg shadow-lg z-50 ${isDark ? "bg-gray-800 border border-gray-700" : "bg-white border border-gray-200"}`,
|
|
143697
|
-
"data-id": "md-editor-table-toolbar",
|
|
143729
|
+
"data-test-id": "md-editor-table-toolbar",
|
|
143698
143730
|
children: [
|
|
143699
143731
|
/* @__PURE__ */ jsxRuntimeExports.jsxs("div", { className: "flex items-center gap-0.5 shrink-0", children: [
|
|
143700
143732
|
/* @__PURE__ */ jsxRuntimeExports.jsx("span", { className: `text-[10px] font-medium uppercase tracking-wide mr-1 ${isDark ? "text-gray-500" : "text-gray-400"}`, children: "Row" }),
|
|
@@ -143705,7 +143737,7 @@ const TableToolbar = ({ editor, theme = "light" }) => {
|
|
|
143705
143737
|
onClick: addRowBefore2,
|
|
143706
143738
|
className: btnBase,
|
|
143707
143739
|
title: "Add row above",
|
|
143708
|
-
"data-id": "md-editor-table-add-row-above",
|
|
143740
|
+
"data-test-id": "md-editor-table-add-row-above",
|
|
143709
143741
|
children: [
|
|
143710
143742
|
/* @__PURE__ */ jsxRuntimeExports.jsx(ArrowUp, { size: 14 }),
|
|
143711
143743
|
/* @__PURE__ */ jsxRuntimeExports.jsx(Plus, { size: 10 })
|
|
@@ -143719,7 +143751,7 @@ const TableToolbar = ({ editor, theme = "light" }) => {
|
|
|
143719
143751
|
onClick: addRowAfter2,
|
|
143720
143752
|
className: btnBase,
|
|
143721
143753
|
title: "Add row below",
|
|
143722
|
-
"data-id": "md-editor-table-add-row-below",
|
|
143754
|
+
"data-test-id": "md-editor-table-add-row-below",
|
|
143723
143755
|
children: [
|
|
143724
143756
|
/* @__PURE__ */ jsxRuntimeExports.jsx(ArrowDown, { size: 14 }),
|
|
143725
143757
|
/* @__PURE__ */ jsxRuntimeExports.jsx(Plus, { size: 10 })
|
|
@@ -143733,7 +143765,7 @@ const TableToolbar = ({ editor, theme = "light" }) => {
|
|
|
143733
143765
|
onClick: deleteRow2,
|
|
143734
143766
|
className: btnDanger,
|
|
143735
143767
|
title: "Delete row",
|
|
143736
|
-
"data-id": "md-editor-table-delete-row",
|
|
143768
|
+
"data-test-id": "md-editor-table-delete-row",
|
|
143737
143769
|
children: /* @__PURE__ */ jsxRuntimeExports.jsx(Minus, { size: 14 })
|
|
143738
143770
|
}
|
|
143739
143771
|
)
|
|
@@ -143748,7 +143780,7 @@ const TableToolbar = ({ editor, theme = "light" }) => {
|
|
|
143748
143780
|
onClick: addColumnBefore2,
|
|
143749
143781
|
className: btnBase,
|
|
143750
143782
|
title: "Add column left",
|
|
143751
|
-
"data-id": "md-editor-table-add-col-left",
|
|
143783
|
+
"data-test-id": "md-editor-table-add-col-left",
|
|
143752
143784
|
children: [
|
|
143753
143785
|
/* @__PURE__ */ jsxRuntimeExports.jsx(ArrowLeft, { size: 14 }),
|
|
143754
143786
|
/* @__PURE__ */ jsxRuntimeExports.jsx(Plus, { size: 10 })
|
|
@@ -143762,7 +143794,7 @@ const TableToolbar = ({ editor, theme = "light" }) => {
|
|
|
143762
143794
|
onClick: addColumnAfter2,
|
|
143763
143795
|
className: btnBase,
|
|
143764
143796
|
title: "Add column right",
|
|
143765
|
-
"data-id": "md-editor-table-add-col-right",
|
|
143797
|
+
"data-test-id": "md-editor-table-add-col-right",
|
|
143766
143798
|
children: [
|
|
143767
143799
|
/* @__PURE__ */ jsxRuntimeExports.jsx(ArrowRight, { size: 14 }),
|
|
143768
143800
|
/* @__PURE__ */ jsxRuntimeExports.jsx(Plus, { size: 10 })
|
|
@@ -143776,7 +143808,7 @@ const TableToolbar = ({ editor, theme = "light" }) => {
|
|
|
143776
143808
|
onClick: deleteColumn2,
|
|
143777
143809
|
className: btnDanger,
|
|
143778
143810
|
title: "Delete column",
|
|
143779
|
-
"data-id": "md-editor-table-delete-col",
|
|
143811
|
+
"data-test-id": "md-editor-table-delete-col",
|
|
143780
143812
|
children: /* @__PURE__ */ jsxRuntimeExports.jsx(Minus, { size: 14 })
|
|
143781
143813
|
}
|
|
143782
143814
|
)
|
|
@@ -143789,7 +143821,7 @@ const TableToolbar = ({ editor, theme = "light" }) => {
|
|
|
143789
143821
|
onClick: deleteTable2,
|
|
143790
143822
|
className: `${btnDanger} shrink-0`,
|
|
143791
143823
|
title: "Delete table",
|
|
143792
|
-
"data-id": "md-editor-table-delete",
|
|
143824
|
+
"data-test-id": "md-editor-table-delete",
|
|
143793
143825
|
children: /* @__PURE__ */ jsxRuntimeExports.jsx(Trash2, { size: 14 })
|
|
143794
143826
|
}
|
|
143795
143827
|
)
|
|
@@ -144266,7 +144298,7 @@ const AIRefinePanel = ({
|
|
|
144266
144298
|
"div",
|
|
144267
144299
|
{
|
|
144268
144300
|
className: `shrink-0 rounded-xl mb-2 border overflow-hidden transition-all duration-300 ${isDark ? "bg-gray-800/80 border-white/10 backdrop-blur-sm" : "bg-white/90 border-black/[0.08] backdrop-blur-sm shadow-sm"}`,
|
|
144269
|
-
"data-id": "md-editor-ai-tips-section",
|
|
144301
|
+
"data-test-id": "md-editor-ai-tips-section",
|
|
144270
144302
|
children: [
|
|
144271
144303
|
/* @__PURE__ */ jsxRuntimeExports.jsxs(
|
|
144272
144304
|
"button",
|
|
@@ -144274,7 +144306,7 @@ const AIRefinePanel = ({
|
|
|
144274
144306
|
type: "button",
|
|
144275
144307
|
onClick: () => setIsTipsExpanded(!isTipsExpanded),
|
|
144276
144308
|
className: `w-full flex items-center justify-between px-3.5 py-2 transition-colors ${isDark ? "hover:bg-white/5" : "hover:bg-black/[0.02]"}`,
|
|
144277
|
-
"data-id": "md-editor-ai-tips-toggle",
|
|
144309
|
+
"data-test-id": "md-editor-ai-tips-toggle",
|
|
144278
144310
|
children: [
|
|
144279
144311
|
/* @__PURE__ */ jsxRuntimeExports.jsxs("div", { className: "flex items-center gap-2", children: [
|
|
144280
144312
|
/* @__PURE__ */ jsxRuntimeExports.jsx("div", { className: `flex items-center justify-center w-5 h-5 rounded-md ${isDark ? "bg-amber-500/20 text-amber-400" : "bg-amber-500/15 text-amber-600"}`, children: /* @__PURE__ */ jsxRuntimeExports.jsx(Zap, { size: 12 }) }),
|
|
@@ -144394,7 +144426,7 @@ const AIRefinePanel = ({
|
|
|
144394
144426
|
className: "flex items-center justify-center w-8 h-8 rounded-lg bg-white/15 text-white cursor-pointer transition-all hover:bg-white/25 hover:scale-105",
|
|
144395
144427
|
onClick: handleReset,
|
|
144396
144428
|
title: "Start over",
|
|
144397
|
-
"data-id": "md-editor-ai-reset-btn",
|
|
144429
|
+
"data-test-id": "md-editor-ai-reset-btn",
|
|
144398
144430
|
children: /* @__PURE__ */ jsxRuntimeExports.jsx(RefreshCw, { size: 16 })
|
|
144399
144431
|
}
|
|
144400
144432
|
),
|
|
@@ -144404,7 +144436,7 @@ const AIRefinePanel = ({
|
|
|
144404
144436
|
className: "flex items-center justify-center w-8 h-8 rounded-lg bg-white/15 text-white cursor-pointer transition-all hover:bg-red-500/80",
|
|
144405
144437
|
onClick: onClose,
|
|
144406
144438
|
title: "Close",
|
|
144407
|
-
"data-id": "md-editor-ai-close-btn",
|
|
144439
|
+
"data-test-id": "md-editor-ai-close-btn",
|
|
144408
144440
|
children: /* @__PURE__ */ jsxRuntimeExports.jsx(X, { size: 18 })
|
|
144409
144441
|
}
|
|
144410
144442
|
)
|
|
@@ -144418,7 +144450,7 @@ const AIRefinePanel = ({
|
|
|
144418
144450
|
"div",
|
|
144419
144451
|
{
|
|
144420
144452
|
className: `relative flex items-start gap-2 w-full px-3 py-2.5 rounded-lg text-left mt-2 transition-all duration-300 border ${isDark ? "bg-white/5 border-white/10" : "bg-black/[0.03] border-black/5"} ${showSelectionHighlight ? "k-md-editor-snake-border" : ""}`,
|
|
144421
|
-
"data-id": "md-editor-ai-selection-box",
|
|
144453
|
+
"data-test-id": "md-editor-ai-selection-box",
|
|
144422
144454
|
children: [
|
|
144423
144455
|
/* @__PURE__ */ jsxRuntimeExports.jsx("span", { className: `shrink-0 px-2 py-0.5 text-[10px] font-semibold uppercase tracking-wide rounded-md transition-all duration-300 ${showSelectionHighlight ? "text-white bg-gradient-to-r from-violet-500 to-indigo-500 scale-105 shadow-md" : isDark ? "text-violet-400 bg-violet-500/20" : "text-violet-600 bg-violet-500/10"}`, children: context.type === "selection" ? "Selection" : "Full" }),
|
|
144424
144456
|
/* @__PURE__ */ jsxRuntimeExports.jsx("div", { className: "flex-1 min-w-0", children: /* @__PURE__ */ jsxRuntimeExports.jsx("span", { className: `text-xs leading-snug break-words ${isDark ? "text-gray-300" : "text-gray-600"} ${isContentExpanded ? "" : "line-clamp-4"}`, children: context.originalText || "(No content selected)" }) }),
|
|
@@ -144429,7 +144461,7 @@ const AIRefinePanel = ({
|
|
|
144429
144461
|
onClick: () => setIsContentExpanded(!isContentExpanded),
|
|
144430
144462
|
className: `shrink-0 p-1 rounded transition-all duration-200 ${isDark ? "text-gray-500 hover:text-gray-300 hover:bg-white/10" : "text-gray-400 hover:text-gray-600 hover:bg-black/5"}`,
|
|
144431
144463
|
title: isContentExpanded ? "Show less" : "Show more",
|
|
144432
|
-
"data-id": "md-editor-ai-expand-btn",
|
|
144464
|
+
"data-test-id": "md-editor-ai-expand-btn",
|
|
144433
144465
|
children: /* @__PURE__ */ jsxRuntimeExports.jsx(
|
|
144434
144466
|
ChevronDown,
|
|
144435
144467
|
{
|
|
@@ -144454,13 +144486,13 @@ const AIRefinePanel = ({
|
|
|
144454
144486
|
/* @__PURE__ */ jsxRuntimeExports.jsx("div", { ref: messagesEndRef })
|
|
144455
144487
|
] }),
|
|
144456
144488
|
/* @__PURE__ */ jsxRuntimeExports.jsxs("div", { className: `flex flex-col gap-2.5 px-3.5 py-3 border-t shrink-0 rounded-b-xl ${isDark ? "bg-gradient-to-b from-transparent to-black/20 border-white/5" : "bg-gradient-to-b from-transparent to-black/[0.02] border-black/5"}`, children: [
|
|
144457
|
-
/* @__PURE__ */ jsxRuntimeExports.jsx("div", { className: "flex flex-wrap gap-1.5", "data-id": "md-editor-ai-quick-actions", children: QUICK_ACTIONS.map((action) => /* @__PURE__ */ jsxRuntimeExports.jsxs(
|
|
144489
|
+
/* @__PURE__ */ jsxRuntimeExports.jsx("div", { className: "flex flex-wrap gap-1.5", "data-test-id": "md-editor-ai-quick-actions", children: QUICK_ACTIONS.map((action) => /* @__PURE__ */ jsxRuntimeExports.jsxs(
|
|
144458
144490
|
"button",
|
|
144459
144491
|
{
|
|
144460
144492
|
className: `flex items-center gap-1 px-2.5 py-1.5 text-xs font-medium rounded-full cursor-pointer transition-all disabled:opacity-50 disabled:cursor-not-allowed ${isDark ? "bg-gray-700 text-gray-300 hover:bg-violet-500 hover:text-white" : "bg-gray-100 text-gray-600 hover:bg-violet-500 hover:text-white"} active:scale-95`,
|
|
144461
144493
|
onClick: () => handleQuickAction(action),
|
|
144462
144494
|
disabled: isLoading,
|
|
144463
|
-
"data-id": `md-editor-ai-action-${action.id}`,
|
|
144495
|
+
"data-test-id": `md-editor-ai-action-${action.id}`,
|
|
144464
144496
|
children: [
|
|
144465
144497
|
action.icon,
|
|
144466
144498
|
/* @__PURE__ */ jsxRuntimeExports.jsx("span", { children: action.label })
|
|
@@ -144473,7 +144505,7 @@ const AIRefinePanel = ({
|
|
|
144473
144505
|
{
|
|
144474
144506
|
ref: mentionMenuRef,
|
|
144475
144507
|
className: `rounded-lg border shadow-lg overflow-hidden max-h-[280px] flex flex-col ${isDark ? "bg-gray-800 border-gray-600" : "bg-white border-gray-200"}`,
|
|
144476
|
-
"data-id": "md-editor-ai-mention-menu",
|
|
144508
|
+
"data-test-id": "md-editor-ai-mention-menu",
|
|
144477
144509
|
children: [
|
|
144478
144510
|
mentionQuery && !selectedCategory && searchResults.length > 0 && /* @__PURE__ */ jsxRuntimeExports.jsxs("div", { className: "py-1 overflow-y-auto", children: [
|
|
144479
144511
|
/* @__PURE__ */ jsxRuntimeExports.jsx("div", { className: `px-3 py-1.5 text-[10px] font-medium uppercase tracking-wide ${isDark ? "text-gray-500" : "text-gray-400"}`, children: "Results" }),
|
|
@@ -144484,7 +144516,7 @@ const AIRefinePanel = ({
|
|
|
144484
144516
|
{
|
|
144485
144517
|
className: `w-full flex items-center gap-2 px-3 py-2 text-left transition-colors ${index === selectedMentionIndex ? isDark ? "bg-violet-500/20 text-violet-300" : "bg-violet-50 text-violet-700" : isDark ? "text-gray-300 hover:bg-white/5" : "text-gray-700 hover:bg-gray-50"}`,
|
|
144486
144518
|
onClick: () => insertMentionItem(item, item.category),
|
|
144487
|
-
"data-id": `md-editor-ai-mention-${isVariable ? item.path : item.id}`,
|
|
144519
|
+
"data-test-id": `md-editor-ai-mention-${isVariable ? item.path : item.id}`,
|
|
144488
144520
|
children: [
|
|
144489
144521
|
/* @__PURE__ */ jsxRuntimeExports.jsx("span", { className: `text-xs px-1.5 py-0.5 rounded ${isDark ? "bg-gray-700 text-gray-400" : "bg-gray-100 text-gray-500"}`, children: item.category }),
|
|
144490
144522
|
/* @__PURE__ */ jsxRuntimeExports.jsx("span", { className: "text-sm font-medium truncate", children: item.name }),
|
|
@@ -144510,7 +144542,7 @@ const AIRefinePanel = ({
|
|
|
144510
144542
|
{
|
|
144511
144543
|
className: `w-full flex items-center justify-between gap-2 px-3 py-2 text-left transition-colors ${index === selectedMentionIndex ? isDark ? "bg-violet-500/20 text-violet-300" : "bg-violet-50 text-violet-700" : isDark ? "text-gray-300 hover:bg-white/5" : "text-gray-700 hover:bg-gray-50"}`,
|
|
144512
144544
|
onClick: () => handleCategorySelect(category.type),
|
|
144513
|
-
"data-id": `md-editor-ai-mention-category-${category.type}`,
|
|
144545
|
+
"data-test-id": `md-editor-ai-mention-category-${category.type}`,
|
|
144514
144546
|
children: [
|
|
144515
144547
|
/* @__PURE__ */ jsxRuntimeExports.jsxs("div", { className: "flex items-center gap-2", children: [
|
|
144516
144548
|
category.icon,
|
|
@@ -144535,7 +144567,7 @@ const AIRefinePanel = ({
|
|
|
144535
144567
|
{
|
|
144536
144568
|
className: `flex items-center gap-1 text-xs transition-colors ${isDark ? "text-gray-400 hover:text-gray-200" : "text-gray-500 hover:text-gray-700"}`,
|
|
144537
144569
|
onClick: handleBackToCategories,
|
|
144538
|
-
"data-id": "md-editor-ai-mention-back",
|
|
144570
|
+
"data-test-id": "md-editor-ai-mention-back",
|
|
144539
144571
|
children: [
|
|
144540
144572
|
/* @__PURE__ */ jsxRuntimeExports.jsx(ChevronRight, { size: 14, className: "rotate-180" }),
|
|
144541
144573
|
/* @__PURE__ */ jsxRuntimeExports.jsx("span", { children: "Back" })
|
|
@@ -144568,7 +144600,7 @@ const AIRefinePanel = ({
|
|
|
144568
144600
|
(_a2 = inputRef.current) == null ? void 0 : _a2.dispatchEvent(new KeyboardEvent("keydown", { key: e3.key, bubbles: true }));
|
|
144569
144601
|
}
|
|
144570
144602
|
},
|
|
144571
|
-
"data-id": "md-editor-ai-mention-search"
|
|
144603
|
+
"data-test-id": "md-editor-ai-mention-search"
|
|
144572
144604
|
}
|
|
144573
144605
|
)
|
|
144574
144606
|
] }) }),
|
|
@@ -144579,7 +144611,7 @@ const AIRefinePanel = ({
|
|
|
144579
144611
|
{
|
|
144580
144612
|
className: `w-full flex flex-col gap-0.5 px-3 py-2 text-left transition-colors ${index === selectedMentionIndex ? isDark ? "bg-violet-500/20 text-violet-300" : "bg-violet-50 text-violet-700" : isDark ? "text-gray-300 hover:bg-white/5" : "text-gray-700 hover:bg-gray-50"}`,
|
|
144581
144613
|
onClick: () => insertMentionItem(item, selectedCategory || void 0),
|
|
144582
|
-
"data-id": `md-editor-ai-mention-item-${isVariable ? item.path : item.id}`,
|
|
144614
|
+
"data-test-id": `md-editor-ai-mention-item-${isVariable ? item.path : item.id}`,
|
|
144583
144615
|
children: [
|
|
144584
144616
|
/* @__PURE__ */ jsxRuntimeExports.jsx("span", { className: "text-sm font-medium", children: item.name }),
|
|
144585
144617
|
isVariable ? /* @__PURE__ */ jsxRuntimeExports.jsx("span", { className: `text-xs truncate ${isDark ? "text-gray-500" : "text-gray-400"}`, children: `{{${selectedCategory}.${item.path}}}` }) : item.description ? /* @__PURE__ */ jsxRuntimeExports.jsx("span", { className: `text-xs truncate ${isDark ? "text-gray-500" : "text-gray-400"}`, children: item.description }) : null
|
|
@@ -144592,7 +144624,7 @@ const AIRefinePanel = ({
|
|
|
144592
144624
|
]
|
|
144593
144625
|
}
|
|
144594
144626
|
),
|
|
144595
|
-
/* @__PURE__ */ jsxRuntimeExports.jsxs("div", { className: `flex items-end gap-2 p-1 rounded-xl border-[1.5px] transition-all ${isDark ? "bg-gray-800 border-gray-600 focus-within:border-violet-500 focus-within:shadow-[0_0_0_4px_rgba(139,92,246,0.2)]" : "bg-white border-gray-200 focus-within:border-violet-500 focus-within:shadow-[0_0_0_4px_rgba(139,92,246,0.1)]"}`, "data-id": "md-editor-ai-input-container", children: [
|
|
144627
|
+
/* @__PURE__ */ jsxRuntimeExports.jsxs("div", { className: `flex items-end gap-2 p-1 rounded-xl border-[1.5px] transition-all ${isDark ? "bg-gray-800 border-gray-600 focus-within:border-violet-500 focus-within:shadow-[0_0_0_4px_rgba(139,92,246,0.2)]" : "bg-white border-gray-200 focus-within:border-violet-500 focus-within:shadow-[0_0_0_4px_rgba(139,92,246,0.1)]"}`, "data-test-id": "md-editor-ai-input-container", children: [
|
|
144596
144628
|
/* @__PURE__ */ jsxRuntimeExports.jsx(
|
|
144597
144629
|
"textarea",
|
|
144598
144630
|
{
|
|
@@ -144604,7 +144636,7 @@ const AIRefinePanel = ({
|
|
|
144604
144636
|
onKeyDown: handleKeyDown2,
|
|
144605
144637
|
rows: 1,
|
|
144606
144638
|
disabled: isLoading,
|
|
144607
|
-
"data-id": "md-editor-ai-input"
|
|
144639
|
+
"data-test-id": "md-editor-ai-input"
|
|
144608
144640
|
}
|
|
144609
144641
|
),
|
|
144610
144642
|
/* @__PURE__ */ jsxRuntimeExports.jsx(
|
|
@@ -144618,7 +144650,7 @@ const AIRefinePanel = ({
|
|
|
144618
144650
|
},
|
|
144619
144651
|
disabled: !inputValue.trim() || isLoading,
|
|
144620
144652
|
title: "Send",
|
|
144621
|
-
"data-id": "md-editor-ai-send-btn",
|
|
144653
|
+
"data-test-id": "md-editor-ai-send-btn",
|
|
144622
144654
|
children: /* @__PURE__ */ jsxRuntimeExports.jsx(Send, { size: 18 })
|
|
144623
144655
|
}
|
|
144624
144656
|
)
|
|
@@ -144631,7 +144663,7 @@ const AIRefinePanel = ({
|
|
|
144631
144663
|
"div",
|
|
144632
144664
|
{
|
|
144633
144665
|
className: "flex flex-col w-[400px] min-w-[340px] max-w-[500px] h-[calc(100%-24px)] m-3 mr-3 ml-0 shrink-0 animate-[ai-panel-slide-in_0.3s_cubic-bezier(0.4,0,0.2,1)]",
|
|
144634
|
-
"data-id": "md-editor-ai-panel-side",
|
|
144666
|
+
"data-test-id": "md-editor-ai-panel-side",
|
|
144635
144667
|
children: [
|
|
144636
144668
|
tipsContent,
|
|
144637
144669
|
/* @__PURE__ */ jsxRuntimeExports.jsx("div", { className: `flex-1 min-h-0 border rounded-2xl overflow-hidden ${isDark ? "border-white/10 shadow-[-4px_0_32px_rgba(0,0,0,0.4)]" : "border-black/[0.08] shadow-[-4px_0_32px_rgba(0,0,0,0.12)]"}`, children: panelContent })
|
|
@@ -144639,13 +144671,13 @@ const AIRefinePanel = ({
|
|
|
144639
144671
|
}
|
|
144640
144672
|
);
|
|
144641
144673
|
case "inline-popup":
|
|
144642
|
-
return /* @__PURE__ */ jsxRuntimeExports.jsxs("div", { className: "fixed inset-0 z-[9999] flex items-center justify-center", "data-id": "md-editor-ai-panel-popup", children: [
|
|
144674
|
+
return /* @__PURE__ */ jsxRuntimeExports.jsxs("div", { className: "fixed inset-0 z-[9999] flex items-center justify-center", "data-test-id": "md-editor-ai-panel-popup", children: [
|
|
144643
144675
|
/* @__PURE__ */ jsxRuntimeExports.jsx(
|
|
144644
144676
|
"div",
|
|
144645
144677
|
{
|
|
144646
144678
|
className: "absolute inset-0 bg-black/60 backdrop-blur-sm animate-[ai-backdrop-in_0.2s_ease-out]",
|
|
144647
144679
|
onClick: onClose,
|
|
144648
|
-
"data-id": "md-editor-ai-panel-backdrop"
|
|
144680
|
+
"data-test-id": "md-editor-ai-panel-backdrop"
|
|
144649
144681
|
}
|
|
144650
144682
|
),
|
|
144651
144683
|
/* @__PURE__ */ jsxRuntimeExports.jsxs("div", { className: "relative w-[90%] max-w-[600px] max-h-[80vh] flex flex-col gap-2 animate-[ai-popup-scale-in_0.3s_cubic-bezier(0.4,0,0.2,1)]", children: [
|
|
@@ -144654,19 +144686,19 @@ const AIRefinePanel = ({
|
|
|
144654
144686
|
] })
|
|
144655
144687
|
] });
|
|
144656
144688
|
case "bottom-drawer":
|
|
144657
|
-
return /* @__PURE__ */ jsxRuntimeExports.jsxs("div", { className: "fixed inset-0 z-[9999] flex flex-col justify-end", "data-id": "md-editor-ai-panel-drawer", children: [
|
|
144689
|
+
return /* @__PURE__ */ jsxRuntimeExports.jsxs("div", { className: "fixed inset-0 z-[9999] flex flex-col justify-end", "data-test-id": "md-editor-ai-panel-drawer", children: [
|
|
144658
144690
|
/* @__PURE__ */ jsxRuntimeExports.jsx(
|
|
144659
144691
|
"div",
|
|
144660
144692
|
{
|
|
144661
144693
|
className: "absolute inset-0 bg-black/60 backdrop-blur-sm",
|
|
144662
144694
|
onClick: onClose,
|
|
144663
|
-
"data-id": "md-editor-ai-panel-backdrop"
|
|
144695
|
+
"data-test-id": "md-editor-ai-panel-backdrop"
|
|
144664
144696
|
}
|
|
144665
144697
|
),
|
|
144666
144698
|
/* @__PURE__ */ jsxRuntimeExports.jsxs("div", { className: "relative w-full max-h-[70vh] flex flex-col gap-2 px-4 pb-4 animate-[ai-drawer-slide-up_0.4s_cubic-bezier(0.4,0,0.2,1)]", children: [
|
|
144667
144699
|
tipsContent,
|
|
144668
144700
|
/* @__PURE__ */ jsxRuntimeExports.jsxs("div", { className: "flex-1 min-h-0 rounded-t-[24px] overflow-hidden shadow-[0_-10px_40px_rgba(0,0,0,0.2)]", children: [
|
|
144669
|
-
/* @__PURE__ */ jsxRuntimeExports.jsx("div", { className: `w-10 h-1 rounded-full mx-auto mt-3 mb-2 ${isDark ? "bg-white/20" : "bg-black/20"}`, "data-id": "md-editor-ai-panel-drawer-handle" }),
|
|
144701
|
+
/* @__PURE__ */ jsxRuntimeExports.jsx("div", { className: `w-10 h-1 rounded-full mx-auto mt-3 mb-2 ${isDark ? "bg-white/20" : "bg-black/20"}`, "data-test-id": "md-editor-ai-panel-drawer-handle" }),
|
|
144670
144702
|
panelContent
|
|
144671
144703
|
] })
|
|
144672
144704
|
] })
|
|
@@ -144676,7 +144708,7 @@ const AIRefinePanel = ({
|
|
|
144676
144708
|
"div",
|
|
144677
144709
|
{
|
|
144678
144710
|
className: "flex flex-col w-[400px] min-w-[340px] max-w-[500px] h-[calc(100%-24px)] m-3 mr-3 ml-0 shrink-0 animate-[ai-panel-slide-in_0.3s_cubic-bezier(0.4,0,0.2,1)]",
|
|
144679
|
-
"data-id": "md-editor-ai-panel",
|
|
144711
|
+
"data-test-id": "md-editor-ai-panel",
|
|
144680
144712
|
children: [
|
|
144681
144713
|
tipsContent,
|
|
144682
144714
|
/* @__PURE__ */ jsxRuntimeExports.jsx("div", { className: `flex-1 min-h-0 border rounded-2xl overflow-hidden ${isDark ? "border-white/10 shadow-[-4px_0_32px_rgba(0,0,0,0.4)]" : "border-black/[0.08] shadow-[-4px_0_32px_rgba(0,0,0,0.12)]"}`, children: panelContent })
|
|
@@ -144757,14 +144789,14 @@ const AIContextMenu = ({
|
|
|
144757
144789
|
ref: menuRef,
|
|
144758
144790
|
className: "ai-context-menu fixed z-[9999] min-w-[180px] bg-gray-800 rounded-lg shadow-xl p-1 overflow-hidden",
|
|
144759
144791
|
style: { top: adjustedPosition.y, left: adjustedPosition.x },
|
|
144760
|
-
"data-id": "md-editor-context-menu",
|
|
144792
|
+
"data-test-id": "md-editor-context-menu",
|
|
144761
144793
|
children: [
|
|
144762
144794
|
/* @__PURE__ */ jsxRuntimeExports.jsxs(
|
|
144763
144795
|
"button",
|
|
144764
144796
|
{
|
|
144765
144797
|
className: "ai-context-menu__item ai-context-menu__item--ai flex items-center gap-2.5 w-full py-2.5 px-3 border-0 rounded-md cursor-pointer bg-violet-500/10 text-violet-400 text-sm font-medium text-left transition-colors duration-150 hover:bg-violet-500/20",
|
|
144766
144798
|
onClick: handleAIRefine,
|
|
144767
|
-
"data-id": "md-editor-context-ai-refine",
|
|
144799
|
+
"data-test-id": "md-editor-context-ai-refine",
|
|
144768
144800
|
children: [
|
|
144769
144801
|
/* @__PURE__ */ jsxRuntimeExports.jsx(Sparkles, { size: 16 }),
|
|
144770
144802
|
/* @__PURE__ */ jsxRuntimeExports.jsx("span", { children: hasSelection2 ? "Refine Selection with AI" : "Refine with AI" }),
|
|
@@ -144779,7 +144811,7 @@ const AIContextMenu = ({
|
|
|
144779
144811
|
{
|
|
144780
144812
|
className: "ai-context-menu__item flex items-center gap-2.5 w-full py-2 px-3 border-0 rounded-md cursor-pointer bg-transparent text-gray-400 text-sm text-left transition-colors duration-150 hover:bg-gray-700 hover:text-white",
|
|
144781
144813
|
onClick: handleCut,
|
|
144782
|
-
"data-id": "md-editor-context-cut",
|
|
144814
|
+
"data-test-id": "md-editor-context-cut",
|
|
144783
144815
|
children: [
|
|
144784
144816
|
/* @__PURE__ */ jsxRuntimeExports.jsx(Scissors, { size: 16 }),
|
|
144785
144817
|
/* @__PURE__ */ jsxRuntimeExports.jsx("span", { children: "Cut" }),
|
|
@@ -144792,7 +144824,7 @@ const AIContextMenu = ({
|
|
|
144792
144824
|
{
|
|
144793
144825
|
className: "ai-context-menu__item flex items-center gap-2.5 w-full py-2 px-3 border-0 rounded-md cursor-pointer bg-transparent text-gray-400 text-sm text-left transition-colors duration-150 hover:bg-gray-700 hover:text-white",
|
|
144794
144826
|
onClick: handleCopy,
|
|
144795
|
-
"data-id": "md-editor-context-copy",
|
|
144827
|
+
"data-test-id": "md-editor-context-copy",
|
|
144796
144828
|
children: [
|
|
144797
144829
|
/* @__PURE__ */ jsxRuntimeExports.jsx(Copy, { size: 16 }),
|
|
144798
144830
|
/* @__PURE__ */ jsxRuntimeExports.jsx("span", { children: "Copy" }),
|
|
@@ -144806,7 +144838,7 @@ const AIContextMenu = ({
|
|
|
144806
144838
|
{
|
|
144807
144839
|
className: "ai-context-menu__item flex items-center gap-2.5 w-full py-2 px-3 border-0 rounded-md cursor-pointer bg-transparent text-gray-400 text-sm text-left transition-colors duration-150 hover:bg-gray-700 hover:text-white",
|
|
144808
144840
|
onClick: handlePaste2,
|
|
144809
|
-
"data-id": "md-editor-context-paste",
|
|
144841
|
+
"data-test-id": "md-editor-context-paste",
|
|
144810
144842
|
children: [
|
|
144811
144843
|
/* @__PURE__ */ jsxRuntimeExports.jsx(Clipboard, { size: 16 }),
|
|
144812
144844
|
/* @__PURE__ */ jsxRuntimeExports.jsx("span", { children: "Paste" }),
|
|
@@ -145538,7 +145570,7 @@ const MDEditor = forwardRef(
|
|
|
145538
145570
|
[editor, insertVariable, insertMention, openAIRefine, closeAIRefine, toggleRawMode, isRawMode]
|
|
145539
145571
|
);
|
|
145540
145572
|
if (!editor) {
|
|
145541
|
-
return /* @__PURE__ */ jsxRuntimeExports.jsx("div", { className: `k-md-editor k-md-editor--${theme} flex items-center justify-center min-h-[200px] ${className}`, "data-id": "md-editor-loading", children: /* @__PURE__ */ jsxRuntimeExports.jsx("div", { className: "w-full h-full min-h-[200px] rounded bg-gradient-to-r from-gray-200 via-gray-100 to-gray-200 dark:from-gray-700 dark:via-gray-600 dark:to-gray-700 bg-[length:200%_100%] animate-pulse" }) });
|
|
145573
|
+
return /* @__PURE__ */ jsxRuntimeExports.jsx("div", { className: `k-md-editor k-md-editor--${theme} flex items-center justify-center min-h-[200px] ${className}`, "data-test-id": "md-editor-loading", children: /* @__PURE__ */ jsxRuntimeExports.jsx("div", { className: "w-full h-full min-h-[200px] rounded bg-gradient-to-r from-gray-200 via-gray-100 to-gray-200 dark:from-gray-700 dark:via-gray-600 dark:to-gray-700 bg-[length:200%_100%] animate-pulse" }) });
|
|
145542
145574
|
}
|
|
145543
145575
|
const isAIEnabled = mergedAIConfig.enabled && onAIRefine && !readOnly;
|
|
145544
145576
|
return /* @__PURE__ */ jsxRuntimeExports.jsxs(
|
|
@@ -145546,7 +145578,7 @@ const MDEditor = forwardRef(
|
|
|
145546
145578
|
{
|
|
145547
145579
|
ref: editorContainerRef,
|
|
145548
145580
|
className: `k-md-editor k-md-editor--${theme} ${readOnly ? "pointer-events-none opacity-80" : ""} ${mergedFeatures.dragDrop ? "k-md-editor--drag-enabled" : ""} ${aiPanelOpen && mergedAIConfig.panelPosition === "side-panel" ? "k-md-editor--ai-panel-open" : ""} ${className}`,
|
|
145549
|
-
"data-id": "md-editor",
|
|
145581
|
+
"data-test-id": "md-editor",
|
|
145550
145582
|
"data-theme": theme,
|
|
145551
145583
|
children: [
|
|
145552
145584
|
/* @__PURE__ */ jsxRuntimeExports.jsxs("div", { className: "k-md-editor__main flex flex-col flex-1 min-w-0 h-full relative transition-[flex] duration-[250ms] ease-[cubic-bezier(0.4,0,0.2,1)]", children: [
|
|
@@ -145649,7 +145681,7 @@ const MDEditor = forwardRef(
|
|
|
145649
145681
|
onClick: toggleRawMode,
|
|
145650
145682
|
className: "absolute top-2 right-2 p-1.5 rounded-md z-10 transition-all duration-200\n bg-white/80 dark:bg-gray-800/80 backdrop-blur-sm\n border border-gray-200 dark:border-gray-700\n hover:bg-gray-100 dark:hover:bg-gray-700\n hover:border-gray-300 dark:hover:border-gray-600\n text-gray-600 dark:text-gray-400\n hover:text-gray-900 dark:hover:text-gray-100\n shadow-sm hover:shadow",
|
|
145651
145683
|
title: isRawMode ? "Switch to rich editor" : "Switch to raw markdown",
|
|
145652
|
-
"data-id": "md-editor-raw-toggle",
|
|
145684
|
+
"data-test-id": "md-editor-raw-toggle",
|
|
145653
145685
|
children: isRawMode ? (
|
|
145654
145686
|
// Eye icon (switch to rich/preview mode)
|
|
145655
145687
|
/* @__PURE__ */ jsxRuntimeExports.jsxs("svg", { className: "w-4 h-4", fill: "none", viewBox: "0 0 24 24", stroke: "currentColor", strokeWidth: 2, children: [
|
|
@@ -145671,7 +145703,7 @@ const MDEditor = forwardRef(
|
|
|
145671
145703
|
onChange: (e3) => handleRawMarkdownChange(e3.target.value),
|
|
145672
145704
|
className: "k-md-editor__raw-textarea w-full h-full min-h-[200px] p-4 pr-12\n font-mono text-sm leading-relaxed resize-none\n bg-gray-50 dark:bg-gray-900\n text-gray-900 dark:text-gray-100\n border-0 focus:outline-none focus:ring-0\n placeholder:text-gray-400 dark:placeholder:text-gray-600",
|
|
145673
145705
|
placeholder: "Write your markdown here...\n\n# Heading\n## Subheading\n- Bullet point\n1. Numbered list\n**bold** _italic_ `code`",
|
|
145674
|
-
"data-id": "md-editor-raw-textarea",
|
|
145706
|
+
"data-test-id": "md-editor-raw-textarea",
|
|
145675
145707
|
spellCheck: false
|
|
145676
145708
|
}
|
|
145677
145709
|
)
|