remove cost from main pages (#1900)

This commit is contained in:
Shuchang Zheng 2025-03-07 12:31:33 -08:00 committed by GitHub
parent fd934dcfe6
commit 7365220a25
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
2 changed files with 8 additions and 19 deletions

View file

@ -111,15 +111,12 @@ function ScrollableActionList({
return (
<div className="h-[40rem] w-1/3 rounded border bg-slate-elevation1">
<div className="grid grid-cols-3 gap-2 p-4">
<div className="flex h-8 items-center justify-center rounded-sm bg-slate-700 px-3 text-xs text-gray-50">
Steps: {taskDetails.steps}
</div>
<div className="grid grid-cols-2 gap-2 p-4">
<div className="flex h-8 items-center justify-center rounded-sm bg-slate-700 px-3 text-xs text-gray-50">
Actions: {taskDetails.actions}
</div>
<div className="flex h-8 items-center justify-center rounded-sm bg-slate-700 px-3 text-xs text-gray-50">
Cost: {taskDetails.cost}
Steps: {taskDetails.steps}
</div>
</div>
<Separator />

View file

@ -1,4 +1,8 @@
import { ScrollArea, ScrollAreaViewport } from "@/components/ui/scroll-area";
import { Skeleton } from "@/components/ui/skeleton";
import { statusIsFinalized, statusIsNotFinalized } from "@/routes/tasks/types";
import { cn } from "@/util/utils";
import { DotFilledIcon } from "@radix-ui/react-icons";
import { useWorkflowRunQuery } from "../hooks/useWorkflowRunQuery";
import { useWorkflowRunTimelineQuery } from "../hooks/useWorkflowRunTimelineQuery";
import {
@ -9,21 +13,12 @@ import {
ObserverThought,
WorkflowRunBlock,
} from "../types/workflowRunTypes";
import { ThoughtCard } from "./ThoughtCard";
import {
ActionItem,
WorkflowRunOverviewActiveElement,
} from "./WorkflowRunOverview";
import { ScrollArea, ScrollAreaViewport } from "@/components/ui/scroll-area";
import { statusIsFinalized, statusIsNotFinalized } from "@/routes/tasks/types";
import { cn } from "@/util/utils";
import { ThoughtCard } from "./ThoughtCard";
import { WorkflowRunTimelineBlockItem } from "./WorkflowRunTimelineBlockItem";
import { DotFilledIcon } from "@radix-ui/react-icons";
const formatter = Intl.NumberFormat("en-US", {
style: "currency",
currency: "USD",
});
type Props = {
activeItem: WorkflowRunOverviewActiveElement;
@ -67,16 +62,13 @@ function WorkflowRunTimeline({
return (
<div className="min-w-0 space-y-4 rounded bg-slate-elevation1 p-4">
<div className="grid grid-cols-3 gap-2">
<div className="grid grid-cols-2 gap-2">
<div className="flex items-center justify-center rounded bg-slate-elevation3 px-4 py-3 text-xs">
Actions: {numberOfActions}
</div>
<div className="flex items-center justify-center rounded bg-slate-elevation3 px-4 py-3 text-xs">
Steps: {workflowRun.total_steps ?? 0}
</div>
<div className="flex items-center justify-center rounded bg-slate-elevation3 px-4 py-3 text-xs">
Cost: {formatter.format(workflowRun.total_cost ?? 0)}
</div>
</div>
<ScrollArea>
<ScrollAreaViewport className="h-[37rem] max-h-[37rem]">