mirror of
https://github.com/Skyvern-AI/skyvern.git
synced 2025-09-01 18:20:06 +00:00
UI improvements (#296)
This commit is contained in:
parent
25a7a3ad8e
commit
6feddbde6a
4 changed files with 8 additions and 12 deletions
|
@ -23,7 +23,7 @@ const CardHeader = React.forwardRef<
|
|||
>(({ className, ...props }, ref) => (
|
||||
<div
|
||||
ref={ref}
|
||||
className={cn("flex flex-col space-y-1.5 p-4", className)}
|
||||
className={cn("flex flex-col space-y-1.5 p-4 bg-muted/40", className)}
|
||||
{...props}
|
||||
/>
|
||||
));
|
||||
|
|
|
@ -86,7 +86,7 @@ const DropdownMenuItem = React.forwardRef<
|
|||
<DropdownMenuPrimitive.Item
|
||||
ref={ref}
|
||||
className={cn(
|
||||
"relative flex cursor-default select-none items-center rounded-sm px-2 py-1.5 text-sm outline-none transition-colors focus:bg-accent focus:text-accent-foreground data-[disabled]:pointer-events-none data-[disabled]:opacity-50",
|
||||
"relative flex cursor-pointer select-none items-center rounded-sm px-2 py-1.5 text-sm outline-none transition-colors focus:bg-accent focus:text-accent-foreground data-[disabled]:pointer-events-none data-[disabled]:opacity-50",
|
||||
inset && "pl-8",
|
||||
className,
|
||||
)}
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
import { getClient } from "@/api/AxiosClient";
|
||||
import { Status, TaskApiResponse } from "@/api/types";
|
||||
import { TaskApiResponse } from "@/api/types";
|
||||
import { useQuery } from "@tanstack/react-query";
|
||||
import { basicTimeFormat } from "@/util/timeFormat";
|
||||
import {
|
||||
|
@ -32,11 +32,7 @@ function QueuedTasks() {
|
|||
},
|
||||
});
|
||||
|
||||
const queuedTasks = tasks
|
||||
?.filter((task) => task.status === Status.Queued)
|
||||
.slice(0, 10);
|
||||
|
||||
if (queuedTasks?.length === 0) {
|
||||
if (tasks?.length === 0) {
|
||||
return <div>No queued tasks</div>;
|
||||
}
|
||||
|
||||
|
@ -50,16 +46,16 @@ function QueuedTasks() {
|
|||
</TableRow>
|
||||
</TableHeader>
|
||||
<TableBody>
|
||||
{queuedTasks?.length === 0 ? (
|
||||
{tasks?.length === 0 ? (
|
||||
<TableRow>
|
||||
<TableCell colSpan={3}>No queued tasks</TableCell>
|
||||
</TableRow>
|
||||
) : (
|
||||
queuedTasks?.map((task) => {
|
||||
tasks?.map((task) => {
|
||||
return (
|
||||
<TableRow
|
||||
key={task.task_id}
|
||||
className="cursor-pointer w-4"
|
||||
className="cursor-pointer w-4 hover:bg-muted/50"
|
||||
onClick={() => {
|
||||
navigate(task.task_id);
|
||||
}}
|
||||
|
|
|
@ -40,7 +40,7 @@ function RunningTasks() {
|
|||
return (
|
||||
<Card
|
||||
key={task.task_id}
|
||||
className="hover:bg-primary-foreground cursor-pointer"
|
||||
className="hover:bg-muted/50 cursor-pointer"
|
||||
onClick={() => {
|
||||
navigate(`/tasks/${task.task_id}`);
|
||||
}}
|
||||
|
|
Loading…
Add table
Reference in a new issue